Hi Evan,

Evan Harrell wrote:
> For some reason when I use pp to package my software, my @INC array is not
> correct. The error I get when I try to run the resulting executable is:

> #!/usr/bin/perl -w -I/home/valdar/perl/include/

That's the culprit. The command line options get lost. This is currently
a bug in PAR(::Packer) and potentially Module::ScanDeps, but it's not
easy to fix as we'd have to redo the whole of perl's command line parsing.

The simple workaround is to do:

#!/usr/bin/perl
use warnings;
use lib '/home/valdar/perl/include/';
...

As for the packaged executable only searching its temporary paths by
default: That's on purpose as the executables are supposed to be
self-contained.

If you want to do away with the fixed path in the executable, try adding
the option -I /home/valdar/perl/include/ to your call to pp and it'll
search modules in that path, too.

Best regards,
Steffen

Reply via email to