Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Invalid type 'Q' & perl2exe

Status
Not open for further replies.

dave82

IS-IT--Management
May 23, 2008
3
IT
Hi all.

I'm trying to convert a .pl script into executable trough "perl2exe" (SonOS and Linux platforms).
The script is perfectly working if ran as .pl.
If I try to run the output generated executable I get the following error:

Invalid type 'Q' in pack at PERL2EXE_STORAGE/Config.pm line 87.
Compilation failed in require at PERL2EXE_STORAGE/File/Copy.pm line 15.
BEGIN failed--compilation aborted at PERL2EXE_STORAGE/File/Copy.pm line 15.
Compilation failed in require at PERL2EXE_STORAGE/utils3.pm line 8.
BEGIN failed--compilation aborted at PERL2EXE_STORAGE/utils3.pm line 8.
Compilation failed in require at /home/ccase/sepg/ccset_env_custom_choice line 9.
BEGIN failed--compilation aborted at /home/ccase/sepg/ccset_env_custom_choice line 9.

perl -V output is:

perl -V
Summary of my perl5 (revision 5 version 8 subversion 6) configuration:
Platform:
osname=solaris, osvers=2.8, archname=sun4-solaris-multi
uname='sunos radium 5.8 generic_117350-26 sun4u sparc sunw,sun-blade-1500 '
config_args='-d -e -O -D cc=cc -D prefix=/opt/rational/common -D perl=ratlperl -D startperl=: -D perlpath=ratlperl -D usemultiplicity -U use5005threads -D usedl -D useshrplib -U usemymalloc -D cf_by=ibm -D cf_email=sw_support@us.ibm.com -D perladmin=sw_support@us.ibm.com -D uselargefiles -D usethreads -D useithreads -D use64bitint -D make=clearmake -OvV -D ldcc=CC -D optimize=-xO4 -fns -fsingle -fsimple=2 -ftrap=%none -xmemalign=8s -xtarget=generic -xbuiltin=%all -xdepend -xlibmil -xlibmopt -xunroll=3 -D libpth=/vobs/sys/SOLARIS/sun5.8/usr/lib -D locincpth=/vobs/sys/SOLARIS/sun5.8/usr/include -U loclibpth= -D lddlflags=-G -L$(PERL_INC) -lratlperl -mt -L/vobs/sys/SOLARIS/sun5.8/usr/lib -norunpath -R/opt/rational/common/shlib -i -xmemalign=8s -Bdynamic -D ldflags=-mt -L/vobs/sys/SOLARIS/sun5.8/usr/lib -norunpath -R/opt/rational/common/shlib -i -xmemalign=8s -Bdynamic -D ccdlflags=-Bdynamic -D dlsrc=dl_dlopen.xs -D ldlibpthname=LD_LIBRARY_PATH -D cccdlflags=-xcode=pic32 -D ccflags=-mt -DPERL_IMPLICIT_CONTEXT -DPERL_USE_SAFE_PUTENV -Xa -xtransition -errfmt -xstrconst -mr -Qn -v -erroff=E_UNRECOGNIZED_PRAGMA_IGNORED,E_STATEMENT_NOT_REACHED,E_SLASH_STAR_IN_CMNT -D libperl=libratlperl.so -D so=so'
hint=recommended, useposix=true, d_sigaction=define
usethreads=define use5005threads=undef useithreads=define usemultiplicity=define
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=define use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='cc', ccflags ='-D_REENTRANT -mt -DPERL_IMPLICIT_CONTEXT -DPERL_USE_SAFE_PUTENV -Xa -xtransition -errfmt -xstrconst -mr -Qn -v -erroff=E_UNRECOGNIZED_PRAGMA_IGNORED,E_STATEMENT_NOT_REACHED,E_SLASH_STAR_IN_CMNT -I/vobs/sys/SOLARIS/sun5.8/usr/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
optimize='-xO4 -fns -fsingle -fsimple=2 -ftrap=%none -xmemalign=8s -xtarget=generic -xbuiltin=%all -xdepend -xlibmil -xlibmopt -xunroll=3',
cppflags='-D_REENTRANT -mt -DPERL_IMPLICIT_CONTEXT -DPERL_USE_SAFE_PUTENV -Xa -xtransition -errfmt -xstrconst -mr -Qn -v -erroff=E_UNRECOGNIZED_PRAGMA_IGNORED,E_STATEMENT_NOT_REACHED,E_SLASH_STAR_IN_CMNT -I/vobs/sys/SOLARIS/sun5.8/usr/include'
ccversion='Sun C 5.6 Patch 117551-04 2005/02/15', gccversion='', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=87654321
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld='cc', ldflags ='-mt -mt -L/vobs/sys/SOLARIS/sun5.8/usr/lib -norunpath -R/opt/rational/common/shlib -i -xmemalign=8s -Bdynamic '
libpth=/vobs/sys/SOLARIS/sun5.8/usr/lib
libs=-lsocket -lnsl -ldl -lm -lpthread -lc
perllibs=-lsocket -lnsl -ldl -lm -lpthread -lc
libc=/lib/libc.so, so=so, useshrplib=true, libperl=libratlperl.so
gnulibc_version=''
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Bdynamic -R /opt/rational/common/lib/perl5/5.8.6/sun4-solaris-multi/CORE'
cccdlflags='-xcode=pic32', lddlflags='-mt -G -L$(PERL_INC) -lratlperl -mt -L/vobs/sys/SOLARIS/sun5.8/usr/lib -norunpath -R/opt/rational/common/shlib -i -xmemalign=8s -Bdynamic'


Characteristics of this binary (from libperl):
Compile-time options: MULTIPLICITY USE_ITHREADS USE_64_BIT_INT USE_LARGE_FILES PERL_IMPLICIT_CONTEXT
Built under solaris
Compiled at Mar 20 2006 11:02:04
@INC:
/opt/rational/common/lib/perl5/5.8.6/sun4-solaris-multi
/opt/rational/common/lib/perl5/5.8.6
/opt/rational/common/lib/perl5/site_perl/5.8.6/sun4-solaris-multi
/opt/rational/common/lib/perl5/site_perl/5.8.6
/opt/rational/common/lib/perl5/site_perl
.

I got the same error on Linux64 host.

Any suggestion?

Many thanks

dave82
 
perlfunc(pack) said:
Q An unsigned quad value.
(Quads are available only if your system supports 64-bit
integer values _and_ if Perl has been compiled to support those.
Causes a fatal error otherwise.)
Admittedly this is from the ActiveState 5.10 windows interpreted version doc, but it does indicate that this is a bit of a dodgy area. Compiling it probably isn't going to make it any better.

Steve

[small]"Every program can be reduced by one instruction, and every program has at least one bug. Therefore, any program can be reduced to one instruction which doesn't work." (Object::perlDesignPatterns)[/small]
 
Hi.

Thanks for your reply.

Perl seems to be compliant.
Performing:
(vobadm@agrus082) .../ccase/sepg> perl -e 'print unpack("Q", pack("Q", 2**38)),"\n";'
274877906944


everything seems to be ok.

dave82
 
Yes, but it doesn't matter if regular interpreted perl can handle it on your box. PERL2EXE is a compiler, so it's a different code base. And it doesn't seem to like it...

Steve

[small]"Every program can be reduced by one instruction, and every program has at least one bug. Therefore, any program can be reduced to one instruction which doesn't work." (Object::perlDesignPatterns)[/small]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top