in reply to Re^15: trying to build PAR-Packer-1.002
in thread trying to build PAR-Packer-1.002

It's only one test that has failed (and it fails for me, too, btw) - looks like there's a problem locating PAR-Packer-1.002\contrib\automated_pp_test\hi.ico.

I'd be tempted to just run 'dmake install' and then start using the module and see how it goes. If you don't mess around with icon files you may well find that your PAR-Packer works perfectly well for you.
And if the problem that caused that test failure ever does jump up and bite you, then that's probably the time to investigate further.

One thing you could try is to open contrib/automated_pp_test.pl and change:
my $cmd = 'pp --gui --icon hi.ico -o ' . "$hello_executable $hello_pl_ +file";
to:
my $cmd = 'pp --gui --icon C:/mybuild/PAR-Packer-1.002/contrib/hi.ico +-o ' . "$hello_executable $hello_pl_file";
Then re-run 'dmake test' and see if the failing test then passes. I'll give that a go myself, when I get a chance. (All we've done is specify the full path to hi.ico.)

I should point out (the obvious) that you shouldn't have to engage in those silly hacks that we've used to get to this point - and I'll try to work out why they were necessary. But there aren't too many modules that venture into the areas that PAR-Packer visits, so it's quite likely that you won't ever come across the same problem again. (Please be sure to /msg me if you do.)

Cheers,
Rob

Replies are listed 'Best First'.
Re^17: trying to build PAR-Packer-1.002
by rich_d_thomas (Sexton) on Mar 22, 2010 at 22:34 UTC
    Hi Rob

    Thanks for those suggestions

    I started on the automated test changes first, becuase once I saw a way of making things better, I couldn't resist! I tried a few varients of the hi.ico path as follows:

    Opened up PERL script C:\mybuild\PAR-Packer-1.002\contrib\automated_pp_test\automated_pp_test.pl

    Changed:

    my $cmd = 'pp --gui --icon hi.ico -o ' . "$hello_executable $hello_pl_ +file";
    To (attempt 1):

    my $cmd = 'pp --gui --icon C:/mybuild/PAR-Packer-1.002/contrib/hi.ico +-o ' . "$hello_executable $hello_pl_file";
    Result:

    t/20-pp.t ................ 31/34 Cannot open C:/mybuild/PAR-Packer-1.0 +02/contrib/hi.ico for reading: No such file or directory at C:/Perl/s +ite/lib/Parse/Binary.pm line 612. # Failed test 'pp_gui_tests # amsg572: sub pp_gui_tests cannot system pp --gui --icon C:/mybuild/P +AR-Packer-1.002/contrib/hi.ico -o hello.exe hello.pl:No such file or +directory: # ' t/20-pp.t ................ 32/34 # at automated_pp_test.pl line 8446 +. t/20-pp.t ................ 34/34 # Looks like you failed 1 test of 34.
    To (attempt 2):

    my $cmd = 'pp --gui --icon C:/mybuild/PAR-Packer-1.002/contrib/automat +ed_pp_test/hi.ico -o ' . "$hello_executable $hello_pl_file";
    Result:

    t/20-pp.t ................ 31/34 Can't call method "remove" on an unde +fined value at C:/Perl/site/lib/Win32/Exe.pm line 220. t/20-pp.t ................ 32/34 # Failed test 'pp_gui_tests # amsg572: sub pp_gui_tests cannot system pp --gui --icon C:/mybuild/P +AR-Packer-1.002/contrib/automated_pp_test/hi.ico -o hello.exe hello.p +l:No such file or directory: # ' # at automated_pp_test.pl line 8446. t/20-pp.t ................ 34/34 # Looks like you failed 1 test of 34.
    To (attempt 3):

    my $cmd = 'pp --gui --icon C:\mybuild\PAR-Packer-1.002\contrib\automat +ed_pp_test\hi.ico -o ' . "$hello_executable $hello_pl_file";
    Result:

    t/20-pp.t ................ 31/34 Can't call method "remove" on an unde +fined value at C:/Perl/site/lib/Win32/Exe.pm line 220. # Failed test 'pp_gui_tests t/20-pp.t ................ 32/34 # amsg572: sub pp_gui_tests cannot sy +stem pp --gui --icon C:\mybuild\PAR-Packer-1.002\contrib\automated_pp +_test\hi.ico -o hello.exe hello.pl:No such file or directory: # ' # at automated_pp_test.pl line 8447. t/20-pp.t ................ 34/34 # Looks like you failed 1 test of 34.
    To (attempt 3):

    my $cmd = 'pp --gui --icon C:\\mybuild\\PAR-Packer-1.002\\contrib\\aut +omated_pp_test\\hi.ico -o ' . "$hello_executable $hello_pl_file";
    Result:

    t/20-pp.t ................ 31/34 Can't call method "remove" on an unde +fined value at C:/Perl/site/lib/Win32/Exe.pm line 220. # Failed test 'pp_gui_tests # amsg572: sub pp_gui_tests cannot system pp --gui --icon C:\mybuild\P +AR-Packer-1.002\contrib\automated_pp_test\hi.ico -o hello.exe hello.p +l:No such file or directory: # ' t/20-pp.t ................ 32/34 # at automated_pp_test.pl line 8448 +. t/20-pp.t ................ 34/34 # Looks like you failed 1 test of 34.
    So I pressed on anyway and did a 'make install' and that did not generate any errors :)

    I had a look around and saw pp, pp.bat and pp.pm files still had date/timestamps in the past.

    So I un-installed PERL and deleted the c:\perl folder and re-did all the dmakes (still needed to manually make par.exe and static.exe

    What happened on the 3rd dmake is the following:

    C:\mybuild\PAR-Packer-1.002>dmake test dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.h]. dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.c]. dmake.exe: Warning: -- Found file corresponding to virtual target [ma +in.c]. C:\Perl\bin\perl.exe run_with_inc.pl static.exe -I../myldr/.. -I../bli +b/lib -q -B -O..\script\parl.exe C:\Perl\bin\perl.exe run_with_inc.pl par.exe -I./myldr/.. -I../blib/li +b -q -B -O..\script\parldyn.exe C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Static.pm');" C:\Perl\bin\perl.exe encode_append.pl static.exe ..\blib\lib\PAR\Strip +pedPARL\Static.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Static.pm');" C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Dynamic.pm');" C:\Perl\bin\perl.exe encode_append.pl par.exe ..\blib\lib\PAR\Stripped +PARL\Dynamic.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Dynamic.pm');" Can't locate PAR/Heavy.pm in @INC (@INC contains: C:/Perl/site/lib C:/ +Perl/lib . ./myldr/.. ../blib/lib C:/Perl/site/lib C:/Perl/lib .) at +-e line 525, <_FH> chunk 1. C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/par +ldyn.exe b lib\script\parldyn.exe dmake.exe: Error: -- `script\parl.exe' not found, and can't be made C:\mybuild\PAR-Packer-1.002>Can't locate PAR/Heavy.pm in @INC (@INC co +ntains: C:/Perl/site/lib C:/Perl/lib . ../myldr/.. ../blib/lib .) at +-e line 525, <_FH> chunk 1.
    It just hangs at the above. Do you have any suggestions on these new errors?

    Thanks

    Richard.

      Can't locate PAR/Heavy.pm in @INC

      Oops ... I don't get that error. Have you installed the prerequisite PAR ?

      Cheers,
      Rob
        Hi Rob

        I had also deleted and re-unpacked the PAR-Packer-1.002 directory.

        I did it again anyway and took more notice of the output of perl Makefile.pl:

        Warning: prerequisite Getopt::ArgvFile 1.07 not found. Warning: prerequisite Module::ScanDeps 0.96 not found. Warning: prerequisite PAR 0.994 not found. Warning: prerequisite PAR::Dist 0.22 not found. Warning: prerequisite Parse::Binary 0.04 not found. Warning: prerequisite Win32::Exe 0.04 not found. Writing Makefile for the par.exe program Writing Makefile for PAR::Packer
        So I installed all of the pre-required packages and did the 3 dmakes again

        It still hung as follows:

        dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.h]. dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.c]. dmake.exe: Warning: -- Found file corresponding to virtual target [ma +in.c]. C:\Perl\bin\perl.exe run_with_inc.pl static.exe -I../myldr/.. -I../bli +b/lib -q -B -O..\script\parl.exe C:\Perl\bin\perl.exe run_with_inc.pl par.exe -I./myldr/.. -I../blib/li +b -q -B -O..\script\parldyn.exe C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Static.pm');" C:\Perl\bin\perl.exe encode_append.pl static.exe ..\blib\lib\PAR\Strip +pedPARL\Static.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Static.pm');" C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Dynamic.pm');" C:\Perl\bin\perl.exe encode_append.pl par.exe ..\blib\lib\PAR\Stripped +PARL\Dynamic.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Dynamic.pm');" dmake.exe: Error: -- `script\parldyn.exe' not found, and can't be mad +e C:\mybuild\PAR-Packer-1.002>Set up gcc environment - 3.4.5 (mingw-vist +a specialr3) Copyright (C) 2004 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There i +s NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PUR +POSE. Set up gcc environment - 3.4.5 (mingw-vista special r3) Copyright (C) 2004 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There i +s NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PUR +POSE.
        So I did a <CTRL>+<C> and re-ran it.

        This time, it resulted in pages of errors, I could not copy-and-paste it all, what I was able to paste is right at the bottom of this posting.

        I uninstalled PERL once after and re-unpacked PAR-Packer-1.002 twice, each time doing the process above and it always generates all these errors. Please could you let me know why this may be happeneing.

        Thank you.

        Richard.

        C:\mybuild\PAR-Packer-1.002>dmake test dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.h]. dmake.exe: Warning: -- Found file corresponding to virtual target [mk +tmpdir.c]. dmake.exe: Warning: -- Found file corresponding to virtual target [ma +in.c]. C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Static .pm');" C:\Perl\bin\perl.exe encode_append.pl static.exe ..\blib\lib\PAR\Strip +pedPARL\St atic.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Static .pm');" C:\Perl\bin\perl.exe -e "chmod(oct('0600'), '..\blib\lib\PAR\StrippedP +ARL\Dynami c.pm');" C:\Perl\bin\perl.exe encode_append.pl par.exe ..\blib\lib\PAR\Stripped +PARL\Dynam ic.pm C:\Perl\bin\perl.exe -e "chmod(oct('0444'), '..\blib\lib\PAR\StrippedP +ARL\Dynami c.pm');" C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/par +ldyn.exe b lib\script\parldyn.exe C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/par +l.exe blib \script\parl.exe C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/tkp +p blib\scr ipt\tkpp pl2bat.bat blib\script\tkpp C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/pp +blib\scrip t\pp pl2bat.bat blib\script\pp C:\Perl\bin\perl.exe "-Iinc" -MExtUtils::Command -e "cp" -- script/par +.pl blib\s cript\par.pl pl2bat.bat blib\script\par.pl C:\Perl\bin\perl.exe "-MExtUtils::Command::MM" "-e" "test_harness(0, ' +inc', 'bli b\lib', 'blib\arch')" t/00-pod.t t/10-parl-generation.t t/20-pp.t t/3 +0-current_ exec.t t/40-packer_cd_option.t t/00-pod.t ............... skipped: Set environment variable PERL_TEST +_POD=1 to test POD t/10-parl-generation.t ... ok t/20-pp.t ................ Can't locate PAR/Filter/PodStrip.pm in @INC + (@INC con tains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\lib ) +at -e line 754, <_FH> chunk 1. t/20-pp.t ................ 1/34 # Failed test 'pp_hello_1 # [430] # Test 1_0 The command string " a.exe " in directory C:\mybuild\PAR-Pa +cker-1.002 \contrib\automated_pp_test\pp_switch_tests\temp1,did not produce :: "h +ello" :: # Instead, it produced :: Usage: a.exe [ -Alib.par ] [ -Idir ] [ -Mmod +ule ] [ sr c.par ] [ program.pl ] # a.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp "hello.pl" produce a.exe? # ' # at automated_pp_test.pl line 7022. Can't locate PAR/Filter/PodStrip.pm in @INC (@INC contains: . C:\Perl\ +lib C:\Per l\lib C:\Perl\site\lib C:\Perl\site\lib ) at -e line 754, <_FH> chunk + 1. t/20-pp.t ................ 2/34 Can't locate PAR/Filter/PodStrip.pm in + @INC (@IN C contains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\li +b ) at -e line 754, <_FH> chunk 1. t/20-pp.t ................ 3/34 # Failed test 'pp_minus_o_foo_foo_do +t_pl_bar_d ot_pl # [430] # Test 3_0 The command string " foo.exe " in directory C:\mybuild\PAR- +Packer-1.0 02\contrib\automated_pp_test\pp_switch_tests\temp0,did not produce :: +"hello foo " :: # Instead, it produced :: Usage: foo.exe [ -Alib.par ] [ -Idir ] [ -Mm +odule ] [ src.par ] [ program.pl ] # foo.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp -o foo.exe "foo.pl" "bar.pl" produce foo.exe? # ' # at automated_pp_test.pl line 7115. t/20-pp.t ................ 5/34 Can't locate PAR/Filter/PodStrip.pm in + @INC (@IN C contains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\li +b ) at -e line 754, <_FH> chunk 1. t/20-pp.t ................ 6/34 Can't locate PAR/Filter/PodStrip.pm in + @INC (@IN C contains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\li +b ) at -e line 754, <_FH> chunk 1. t/20-pp.t ................ 10/34 Can't locate PAR/Filter/PodStrip.pm i +n @INC (@I NC contains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\l +ib ) at - e line 754, <_FH> chunk 1. # Failed test 'pp_minus_e_print_hello # [430] # Test 11_0 The command string " a.exe " in directory C:\mybuild\PAR-P +acker-1.00 2\contrib\automated_pp_test\pp_switch_tests\temp2,did not produce :: " +hello" :: t/20-pp.t ................ 11/34 # Instead, it produced :: Usage: a.ex +e [ -Alib. par ] [ -Idir ] [ -Mmodule ] [ src.par ] [ program.pl ] # a.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp -e "print \"hello\n\";" produce a.exe? # ' # at automated_pp_test.pl line 7495. t/20-pp.t ................ 13/34 Can't locate PAR/Filter/PodStrip.pm i +n @INC (@I NC contains: . C:\Perl\lib C:\Perl\lib C:\Perl\site\lib C:\Perl\site\l +ib ) at - e line 754, <_FH> chunk 1. # Failed test 'pp_minus_c_hello t/20-pp.t ................ 14/34 # [430] # Test 14_0 The command string " a.exe " in directory C:\mybuild\PAR-P +acker-1.00 2\contrib\automated_pp_test\pp_switch_tests\temp2,did not produce :: " +hello" :: # Instead, it produced :: Usage: a.exe [ -Alib.par ] [ -Idir ] [ -Mmod +ule ] [ sr c.par ] [ program.pl ] # a.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp -c "hello.pl" produce a.exe? # ' # at automated_pp_test.pl line 7632. Can't locate PAR/Filter/PodStrip.pm in @INC (@INC contains: . C:\Perl\ +lib C:\Per l\lib C:\Perl\site\lib C:\Perl\site\lib ) at -e line 754, <_FH> chunk + 1. t/20-pp.t ................ 15/34 # Failed test 'pp_minus_x_hello # [430] # Test 15_0 The command string " a.exe " in directory C:\mybuild\PAR-P +acker-1.00 2\contrib\automated_pp_test\pp_switch_tests\temp0,did not produce :: " +hello" :: # Instead, it produced :: Usage: a.exe [ -Alib.par ] [ -Idir ] [ -Mmod +ule ] [ sr c.par ] [ program.pl ] # a.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp -x "hello.pl" produce a.exe? # ' # at automated_pp_test.pl line 7680. Can't locate PAR/Filter/PodStrip.pm in @INC (@INC contains: . C:\Perl\ +lib C:\Per l\lib C:\Perl\site\lib C:\Perl\site\lib ) at -e line 754, <_FH> chunk + 1. t/20-pp.t ................ 16/34 # Failed test 'pp_minus_n_minus_x_h +ello # [430] # Test 16_0 The command string " a.exe " in directory C:\mybuild\PAR-P +acker-1.00 2\contrib\automated_pp_test\pp_switch_tests\temp1,did not produce :: " +hello" :: # Instead, it produced :: Usage: a.exe [ -Alib.par ] [ -Idir ] [ -Mmod +ule ] [ sr c.par ] [ program.pl ] # a.exe [ -B|-b ] [-Ooutfile] src.par # Can't locate File/Temp.pm in @INC (@INC contains: .) at -e line 161. # END failed--call queue aborted at -e line 969. :: # End of [430] results # # Did pp -n -x "hello.pl" produce a.exe? # ' # at automated_pp_test.pl line 7728. Can't locate PAR/Filter/PodStrip.pm in @INC (@INC contains: . C:\Perl\ +lib C:\Per l\lib C:\Perl\site\lib C:\Perl\site\lib ) at -e line 754, <_FH> chunk + 1.
      It just hangs at the above

      Yes - it does the same for me whenever I do a 'dmake realclean' followed by a rebuild. Just hit Ctrl-C, then run 'dmake test' again and it should work. Failing that, you could start with a fresh unpack of PAR-Packer-1.002 in a different location. This problem, and the failing test, are both things that should be reported as PAR-Packer bugs. (I think the problems building the executables are, however, *not* PAR-Packer bugs.)

      Cheers,
      Rob