我正在使用 MS-Windows 7 PC - 64 位。我正在使用“DWIM Perl for Windows”(http://dwimperl.com/windows.html)——它是 Strawberry Perl 的衍生产品。
我正在尝试从 cpan 运行“安装 PAR::Packer”——但失败了。全文见下文。
我确实在这里看到了从 cpan“命令行”运行“look PAR::Packer”的建议。但是 - 这也失败了,并显示以下错误消息:
C:\Dwimperl\perl\bin\perl.exe encode_append.pl Dynamic.in par.exe Dynamic.pm
C:\Dwimperl\perl\bin\perl.exe file2c.pl -c 30000 par.exe C:\Dwimperl\perl\bin\pe rl514.dll C:\Dwimperl\perl\bin\libgcc_s_sjlj-1.dll C:./Program > boot_embedded_files.c
open input file 'C:./Program': No such file or directory at file2c.pl line 43.
dmake: Error code 130, while making 'boot_embedded_files.c'
dmake: 'boot_embedded_files.c' removed.
dmake: Error code 255, while making 'subdirs'
这是“安装 PAR::Packer”的失败:
cpan> install PAR::Packer
Running install for module 'PAR::Packer'
Running make for R/RS/RSCHUPP/PAR-Packer-1.014.tar.gz
Checksum for C:\Dwimperl\cpan\sources\authors\id\R\RS\RSCHUPP\PAR-Packer-1.014.t
ar.gz ok
Scanning cache C:\Dwimperl\cpan\build for sizes
............................................................................DONE
CPAN.pm: Building R/RS/RSCHUPP/PAR-Packer-1.014.tar.gz
Checking if your kit is complete...
Looks good
Prototype mismatch: sub main::prompt: none vs ($;$) at C:/Dwimperl/perl/lib/ExtU
tils/MakeMaker.pm line 219
Writing Makefile for par.exe
Writing MYMETA.yml and MYMETA.json
Writing Makefile for PAR::Packer
Writing MYMETA.yml and MYMETA.json
cp lib/App/Packer/PAR.pm blib\lib\App\Packer\PAR.pm
cp lib/PAR/Packer.pm blib\lib\PAR\Packer.pm
cp lib/PAR/Filter/Obfuscate.pm blib\lib\PAR\Filter\Obfuscate.pm
cp lib/PAR/Filter/PodStrip.pm blib\lib\PAR\Filter\PodStrip.pm
cp lib/PAR/StrippedPARL/Base.pm blib\lib\PAR\StrippedPARL\Base.pm
cp lib/PAR/Filter.pm blib\lib\PAR\Filter.pm
cp lib/PAR/Filter/PatchContent.pm blib\lib\PAR\Filter\PatchContent.pm
cp lib/PAR/Filter/Bytecode.pm blib\lib\PAR\Filter\Bytecode.pm
cp lib/pp.pm blib\lib\pp.pm
cp lib/PAR/Filter/Bleach.pm blib\lib\PAR\Filter\Bleach.pm
C:\Dwimperl\perl\bin\perl.exe par_pl2c.pl my_par_pl < ..\script\par.pl > my_par_
pl.c
C:\Dwimperl\perl\bin\perl.exe sha1.c.PL
gcc -c -s -O2 -DWIN32 -DPERL_TEXTMODE_SCRIPTS -DUSE_SITECUSTOMIZE -DPERL_IMPLIC
IT_CONTEXT -DPERL_IMPLICIT_SYS -fno-strict-aliasing -mms-bitfields -I"C:\Dwimpe
rl\perl\lib\CORE" -DPARL_EXE=\"parl.exe\" -s -O2 main.c
main.c: In function 'main':
main.c:121: warning: assignment discards qualifiers from pointer target type
rem
windres -i winres\pp.rc -o ppresource.coff --input-format=rc --output-format=cof
f --target=pe-i386
g++ main.o ppresource.coff -s -s -L"C:\Dwimperl\perl\lib\CORE" -L"C:\Dwimperl\
c\lib" C:\Dwimperl\perl\lib\CORE\libperl514.a C:\Dwimperl\c\i686-w64-mingw32\li
b\libmoldname.a C:\Dwimperl\c\i686-w64-mingw32\lib\libkernel32.a C:\Dwimperl\c\i
686-w64-mingw32\lib\libuser32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libgdi32.a C:
\Dwimperl\c\i686-w64-mingw32\lib\libwinspool.a C:\Dwimperl\c\i686-w64-mingw32\li
b\libcomdlg32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libadvapi32.a C:\Dwimperl\c\i
686-w64-mingw32\lib\libshell32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libole32.a C
:\Dwimperl\c\i686-w64-mingw32\lib\liboleaut32.a C:\Dwimperl\c\i686-w64-mingw32\l
ib\libnetapi32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libuuid.a C:\Dwimperl\c\i686
-w64-mingw32\lib\libws2_32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libmpr.a C:\Dwim
perl\c\i686-w64-mingw32\lib\libwinmm.a C:\Dwimperl\c\i686-w64-mingw32\lib\libver
sion.a C:\Dwimperl\c\i686-w64-mingw32\lib\libodbc32.a C:\Dwimperl\c\i686-w64-min
gw32\lib\libodbccp32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libcomctl32.a -o par.e
xe
rem
C:\Dwimperl\perl\bin\perl.exe encode_append.pl Dynamic.in par.exe Dynamic.pm
C:\Dwimperl\perl\bin\perl.exe file2c.pl -c 30000 par.exe C:\Dwimperl\perl\bin\pe
rl514.dll C:\Dwimperl\perl\bin\libgcc_s_sjlj-1.dll C:./Program > boot_embedded_f
iles.c
open input file 'C:./Program': No such file or directory at file2c.pl line 43.
dmake: Error code 130, while making 'boot_embedded_files.c'
dmake: 'boot_embedded_files.c' removed.
dmake.EXE: Error code 255, while making 'subdirs'
RSCHUPP/PAR-Packer-1.014.tar.gz
C:\Dwimperl\c\bin\dmake.EXE -- NOT OK
Running make test
Can't test without successful make
Running make install
Make had returned bad status, install seems impossible
Failed during this command:
RSCHUPP/PAR-Packer-1.014.tar.gz : make NO
这是从 cpan shell 运行“look PAR::Packer”后得到的结果:
cpan> look PAR::Packer
Running look for module 'PAR::Packer'
Trying to open a subshell in the build directory...
Working directory is C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>perl Makefile.PL
Prototype mismatch: sub main::prompt: none vs ($;$) at C:/Dwimperl/perl/lib/ExtU
tils/MakeMaker.pm line 219
Writing Makefile for par.exe
Writing MYMETA.yml and MYMETA.json
Writing Makefile for PAR::Packer
Writing MYMETA.yml and MYMETA.json
在这里,我也尝试自己运行“DMAKE”:
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>dmake -f Makefile install
Skip blib\lib\App\Packer\PAR.pm (unchanged)
Skip blib\lib\PAR\Packer.pm (unchanged)
Skip blib\lib\PAR\Filter\Obfuscate.pm (unchanged)
Skip blib\lib\PAR\Filter\PodStrip.pm (unchanged)
Skip blib\lib\PAR\StrippedPARL\Base.pm (unchanged)
Skip blib\lib\PAR\Filter.pm (unchanged)
Skip blib\lib\PAR\Filter\PatchContent.pm (unchanged)
Skip blib\lib\PAR\Filter\Bytecode.pm (unchanged)
Skip blib\lib\pp.pm (unchanged)
Skip blib\lib\PAR\Filter\Bleach.pm (unchanged)
gcc -c -s -O2 -DWIN32 -DPERL_TEXTMODE_SCRIPTS -DUSE_SITECUSTOMIZE -DPERL_IMPLIC
IT_CONTEXT -DPERL_IMPLICIT_SYS -fno-strict-aliasing -mms-bitfields -I"C:\Dwimpe
rl\perl\lib\CORE" -DPARL_EXE=\"parl.exe\" -s -O2 main.c
main.c: In function 'main':
main.c:121: warning: assignment discards qualifiers from pointer target type
g++ main.o ppresource.coff -s -s -L"C:\Dwimperl\perl\lib\CORE" -L"C:\Dwimperl\
c\lib" C:\Dwimperl\perl\lib\CORE\libperl514.a C:\Dwimperl\c\i686-w64-mingw32\li
b\libmoldname.a C:\Dwimperl\c\i686-w64-mingw32\lib\libkernel32.a C:\Dwimperl\c\i
686-w64-mingw32\lib\libuser32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libgdi32.a C:
\Dwimperl\c\i686-w64-mingw32\lib\libwinspool.a C:\Dwimperl\c\i686-w64-mingw32\li
b\libcomdlg32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libadvapi32.a C:\Dwimperl\c\i
686-w64-mingw32\lib\libshell32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libole32.a C
:\Dwimperl\c\i686-w64-mingw32\lib\liboleaut32.a C:\Dwimperl\c\i686-w64-mingw32\l
ib\libnetapi32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libuuid.a C:\Dwimperl\c\i686
-w64-mingw32\lib\libws2_32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libmpr.a C:\Dwim
perl\c\i686-w64-mingw32\lib\libwinmm.a C:\Dwimperl\c\i686-w64-mingw32\lib\libver
sion.a C:\Dwimperl\c\i686-w64-mingw32\lib\libodbc32.a C:\Dwimperl\c\i686-w64-min
gw32\lib\libodbccp32.a C:\Dwimperl\c\i686-w64-mingw32\lib\libcomctl32.a -o par.e
xe
rem
C:\Dwimperl\perl\bin\perl.exe encode_append.pl Dynamic.in par.exe Dynamic.pm
C:\Dwimperl\perl\bin\perl.exe file2c.pl -c 30000 par.exe C:\Dwimperl\perl\bin\pe
rl514.dll C:\Dwimperl\perl\bin\libgcc_s_sjlj-1.dll C:./Program > boot_embedded_f
iles.c
open input file 'C:./Program': No such file or directory at file2c.pl line 43.
dmake: Error code 130, while making 'boot_embedded_files.c'
dmake: 'boot_embedded_files.c' removed.
dmake: Error code 255, while making 'subdirs'
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>gvim Makefile.PL
'gvim' is not recognized as an internal or external command,
operable program or batch file.
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j> Makefile.PL
C:\Dwimperl\cpan\build\PAR-Packer-1.014-81Pw9j>