Skip Menu |

This queue is for tickets about the Module-ScanDeps CPAN distribution.

Report information
The Basics
Id: 118320
Status: rejected
Priority: 0/
Queue: Module-ScanDeps

People
Owner: RSCHUPP [...] cpan.org
Requestors: NHORNE [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: won't build gedcal (https://github.com/nigelhorne/gedcal)
$ pp -c gedcal # Use of runtime loader module Module::Implementation detected. Results of static scanning may be incomplete. # Use of runtime loader module Module::Runtime detected. Results of static scanning may be incomplete. /tmp/DzR8onGraQ syntax OK $ ./a.out Error opening Lingua/EN/ABC/abc.json: No such file or directory at Lingua/EN/ABC.pm line 19. Compilation failed in require at script/gedcal line 35. BEGIN failed--compilation aborted at script/gedcal line 35. $ pp -x gedcal # Use of runtime loader module Module::Implementation detected. Results of static scanning may be incomplete. # Use of runtime loader module Module::Runtime detected. Results of static scanning may be incomplete. Usage: gedcal [ -a ] [ -b ] [ -c ] [ -d ] [ -D ] [ -f ] [ -h home-person-name ] [ -H [ -L ] [ -m month ] [ -y year ] ] [ -l ] [ -p person-to-print ] [ -t ] [ -w ] filename [ filename2 ] SYSTEM ERROR in executing gedcal : 65280 at /home/njh/perl5/perlbrew/perls/perl-5.24.0/lib/site_perl/5.24.0/Module/ScanDeps.pm line 1442.
On 2016-10-09 20:05:24, NHORNE wrote: Show quoted text
>... > Error opening Lingua/EN/ABC/abc.json: No such file or directory at Lingua/EN/ABC.pm line 19.
Sorry, this won't work since Lingua::EN::ABC loads abc.json with my $json = __FILE__; $json =~ s!\.pm$!/abc.json!; my $abc = json_file_to_perl ($json); There are two problems here: (1) There's no way that Module::ScanDeps can figure out from scanning Lingua/EN/ABC.pm that it should add a dependency on Lingua/EN/ABC/abc.json. Hence this file will not be packed by pp into your executable. (2) But even if it were packed the above will fail to load it, as __FILE__ is set to "Lingua/EN/ABC.pm" (note the absence of a directory) when the module is loaded running in a packed environment. In theory (1) can be solved with minimal effort by adding a special rule to Module::ScanDeps, but that still leaves (2). Cheers, Roderich that