http://www.perlmonks.org?node_id=11134818


in reply to Re^2: Symlinks with PAR::Packer not working on Windows
in thread Symlinks with PAR::Packer not working on Windows

Do you get the same problem if you only pack one script?

Also, it would be useful to output the contents of some of the PAR environment variables to see what PAR thinks it is dealing with, for example PAR_0, PAR_PROGNAME and PAR_GLOBAL_TEMP. See PAR::Environment. That's assuming it gets that far, of course.

use 5.010; say $ENV{PAR_0}; say $ENV{PAR_PROGNAME}; say $ENV{PAR_GLOBAL_TEMP}; say $0;

More generally, in the past when I've packed multiple scripts I usually packed the first (child) script as an exe, and then included that as an extra file resource when packing the parent script (using the --addfile argument). The parent script can use logic based on $ENV{PAR_0} to decide if it should call a perl script or a packed executable. Any packed resource will be under $ENV{PAR_TMP}/inc.

This approach leads to duplication in what is packed because dependencies are packed separately in each exe. However, it is simpler to wrangle and duplication is not really an issue unless there are large dependencies.