Wed Jul 29 19:42:33 2015: Request 106144 was acted upon.
Transaction: Correspondence added by SLAFFAN
Queue: Module-ScanDeps
Subject: [Patch] Preload dependencies for File::BOM
Broken in: (no value)
Severity: (no value)
Owner: Nobody
Requestors: [email protected]
Status: open
Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=106144 >
Actually, if you agree that the Encode::* modules do need to be preloaded then
it should be under Encode or Encode::Config, not File::BOM.
Encode::Config lists a number of other modules that are loaded on demand, and
seem not to be detected by static scanning or using the execute flag.
Regards,
Shawn.
On Wed Jul 29 17:45:38 2015, SLAFFAN wrote:
> Thanks Roderich.
>
> The issue is that, without the additional encodings, a PAR packed
> executable fails in those locales that need them. An example from my
> use case is here: https://github.com/shawnlaffan/biodiverse/issues/506
>
> The issue boils down to whether they should be implicitly loaded by
> Module::ScanDeps, or should be explicitly packaged in the pp call.
>
>
>
> Regards,
> Shawn.
>
>
> On Wed Jul 29 11:10:31 2015, RSCHUPP wrote:
> > > The patch was tested using the code below. The file open is needed
> > > to
> > > trigger the loading of the extra modules under "pp -x".
> > >
> > > use File::BOM;
> > > open my $fh, '<:via(File::BOM)', $0 # just read ourselves
> > > or die "Cannot open own code via File::BOM\n";
> > > $fh->close;
> >
> > 'File/BOM.pm' => [qw( Encode/Unicode.pm PerlIO/via.pm )],
> >
> > is enough to make the code above work. No need to load a bunch of
> > unrelated encodings.
> >
> > Cheers, Roderich