Hi,

My build machine is a linux amd64 box.  I would like to package a perl script
with par to run on a target machine that is running 32 bit linux.  I'm not
trying to create a binary, just a perl script with the necessary CPAN modules
built into it. Both machines are running the same linux distribution (ubuntu
feisty), essentially the only difference is that my build machine is 64 bit and
has PAR installed and my target machine is 32 bit and does not.  I haven't had
any success and while debugging the problem have found that even a one liner
perl script won't work.  I execute the following on my build machine:

# uname -a
Linux build_host 2.6.20-9-generic #2 SMP Sun Feb 25 22:59:06 UTC 2007 x86_64 
GNU/Linux
# pp -P -e 'print "hello\n"' -o hello.pl

Then copy the file hello.pl to my target machine and try to execute it:

# uname -a
Linux target_host 2.6.20-9-generic #2 SMP Mon Feb 26 03:01:44 UTC 2007 i686 
GNU/Linux

# perl hello.pl
Can't load 
'/tmp/par-jason/cache-95b09bf6309003e83dd9fe81b2a281b8af3a0115/3fa0c988.so' for 
module IO: 
/tmp/par-jason/cache-95b09bf6309003e83dd9fe81b2a281b8af3a0115/3fa0c988.so: 
wrong ELF class: ELFCLASS64 at /usr/lib/perl/5.8/DynaLoader.pm line 225.
 at /usr/share/perl5/PAR/Heavy.pm line 81
Compilation failed in require at /usr/lib/perl/5.8/IO/Handle.pm line 9.
BEGIN failed--compilation aborted at /usr/lib/perl/5.8/IO/Handle.pm line 9.
Compilation failed in require at /usr/lib/perl/5.8/IO/Seekable.pm line 9.
BEGIN failed--compilation aborted at /usr/lib/perl/5.8/IO/Seekable.pm line 9.
Compilation failed in require at /usr/lib/perl/5.8/IO/File.pm line 11.
BEGIN failed--compilation aborted at /usr/lib/perl/5.8/IO/File.pm line 11.
Compilation failed in require at /usr/bin/par.pl line 316.


Am I trying to do something that won't work?  I would have expected to have a
problem if I tried to build an executable, but I would think that a standalone
perl script would work.  Both machines are running perl 5.8.8 and the build
machine is using PAR version 0.952.

Thanks

Reply via email to