Skip to content

Module::Build omits declared nested Perl module from blib #1432

Description

@fglock

Summary

AudioFile::Info::MP3::Tag v1.6.4 fails under PerlOnJava because the Module::Build-based build omits its declared plugin module from blib/lib.

The distribution source contains lib/AudioFile/Info/MP3/Tag.pm, and META.yml correctly provides AudioFile::Info::MP3::Tag, but after the PerlOnJava Build step the generated blib/lib contains AudioFile/Info/Build.pm and does not contain AudioFile/Info/MP3/Tag.pm.

Evidence

  • CPAN run: 20260918-141920-96054
  • Distribution: AudioFile::Info::MP3::Tag v1.6.4
  • System Perl: PASS, 4 files and 25 tests
  • PerlOnJava: FAIL, 3/4 test programs and 2/6 reported subtests

The PerlOnJava failure is:

Can't locate object method "new" via package "AudioFile::Info::MP3::Tag"

It occurs in AudioFile::Info::Info.pm while the plugin-backed tests are trying to construct the MP3 handler. The same missing plugin also causes both POD-coverage checks to report that requiring AudioFile::Info::MP3::Tag failed.

The source package has:

lib/AudioFile/Info/MP3/Tag.pm

but the resulting build tree contains only:

blib/lib/AudioFile/Info/Build.pm

and no blib/lib/AudioFile/Info/MP3/Tag.pm.

Reproduction

Run the CPAN test for AudioFile::Info::MP3::Tag v1.6.4 with PerlOnJava. The dependency builds complete, including AudioFile::Info and MP3::Tag, but the final Build test fails in t/1_read.t, t/2_write.t, and t/4_pod_coverage.t because the plugin is not available from the build output.

The relevant build output reports AudioFile::Info-MP3-Tag as built successfully, despite the missing module file.

Expected behavior

A successful Module::Build build must copy every declared Perl module from lib/ into the corresponding blib/lib/ path. In this case it should produce:

blib/lib/AudioFile/Info/MP3/Tag.pm

The subsequent test environment should then be able to load the plugin and run the 25 tests successfully, matching system Perl.

Requested fix

Investigate PerlOnJava's Module::Build file-discovery or staging logic for nested module paths and ensure that ordinary declared pure-Perl modules are copied into blib/lib during Build.

Add focused regression coverage that verifies a nested module such as AudioFile::Info::MP3::Tag is present in blib/lib after a Module::Build build, then rerun the distribution's test suite.

Related issues

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:cpan-portCPAN compatibility ports and providersarea:releaseBuild release and project workflowbugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions