On 23 Dec 2004 at 13:24, Mike Schroeder wrote:
> I've been using PAR with wxPerl for quite a while and all seems fine. I
> just updated my win2k build box to PAR 0.86 and now things break (PAR
> 0.86 seems to work fine in Linux). Using the minimal.pl sample from
> wxPerl I try:
>
> pp -o minwx.exe minimal.pl
>
> And it builds minwx.exe without errors. When I try to run minwx.exe
> though, I first get a "Unable to Locate DLL" popup box that says:
>
> The dynamic link library wxmsw252u_adv_vc_custom.dll could not be found
> in the specified path
> C:\DOCUME~1\MIKESC~1\LOCALS~1\Temp\par-Mike_Schroeder\cache-1103829904;.;
> C:\WINNT\System32;C:\WINNT\system;C:\WINNT;
> C:\DOCUME~1\MIKESC~1\LOCALS~1\Temp\par-Mike_Schroeder\cache-1103829904;
> C:\Perl\bin\;C:\WINNT\System32;C:\WINNT;C:\WINNT\System32\Wbem.
>
> And on the console, I get:
>
> C:\src>minwx.exe
> Can't load
> 'C:\DOCUME~1\MIKESC~1\LOCALS~1\Temp\par-Mike_Schroeder\cache-11038299
> 04\2cb94e35.dll' for module Wx: load_file:The specified module could not
> be foun
> d at C:/aperl58/lib/DynaLoader.pm line 231.
> at ../blib/lib/PAR/Heavy.pm line 107
> Compilation failed in require at script/minimal.pl line 14.
> BEGIN failed--compilation aborted at script/minimal.pl line 14.
>
> However, the offending dll (wxmsw252u_adv_vc_custom.dll) is indeed in
> the exe (double checked with winzip) in the lib\auto\Wx\ directory.
>
> I also ran the automted_pp_test.pl and it is fine (except for test 31 i
> think).
>
> My next test was to go back to an older version of PAR -- the
> ActiveState repository had 0.75 (eek) -- but it at least built
> functional wxPerl apps.
>
> Is this a bug in PAR 0.86, or do I have a weird build environment?
PAR 0.86 has some changes to eliminate redundant unpacking, but that means that
any DLL
that is loaded indirectly by another DLL, rather than loaded by a Perl module
needs to
be packed with the -l option so it will be packed in a shared lib directory and
unpacked into the temp directory next to the DLL that loads it, where it can be
found.
pp -l <full_path>/wxmsw252u_adv_vc_custom.dll -o minwx.exe minimal.pl
Alan Stewart