Tue Dec 13 14:38:16 2016: Request 118320 was acted upon.
Transaction: Correspondence added by RSCHUPP
       Queue: Module-ScanDeps
     Subject: won't build gedcal (https://github.com/nigelhorne/gedcal)
   Broken in: (no value)
    Severity: (no value)
       Owner: RSCHUPP
  Requestors: nho...@cpan.org
      Status: new
 Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=118320 >


On 2016-10-09 20:05:24, NHORNE wrote:
>...
> 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

Reply via email to