How can I build the Perl extension XMLSablotron

De openkb
Aller à : Navigation, rechercher

Sommaire

Questions

http://search.cpan.org/perldoc/XML%3a%3aSablotron http://search.cpan.org/perldoc/XML%3a%3aSablotron

perl -V

Summary of my perl5 (revision 5 version 14 subversion 2) configuration:
Platform:
osname=cygwin, osvers=1.7.15(0.26053), archname=cygwin-thread-multi-64int
uname= cygwin_nt-5.1 winxp 1.7.15(0.26053) 2012-05-09 10:25 i686 cygwin  
config_args= -de -Dlibperl=cygperl5_14.dll -Dcc=gcc-4 -Dld=g++-4 -Darchname=                       i686-cygwin-threads-64int -Dmksymlinks -Dusethreads -Accflags=-g 
hint=recommended, useposix=true, d_sigaction=define
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= gcc-4 , ccflags = -DPERL_USE_SAFE_PUTENV -U__STRICT_ANSI__ -g -fno-stric                       t-aliasing -pipe -fstack-protector ,
optimize= -O3 ,
cppflags= -DPERL_USE_SAFE_PUTENV -U__STRICT_ANSI__ -g -fno-strict-aliasing -                       pipe -fstack-protector 
ccversion=  , gccversion= 4.5.3 , gccosandvers=  
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype= long long , ivsize=8, nvtype= double , nvsize=8, Off_t= off_t , lsee                       ksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld= g++-4 , ldflags =  -Wl,--enable-auto-import -Wl,--export-all-symbols -Wl                       ,--enable-auto-image-base -fstack-protector -L/usr/local/lib 
libpth=/usr/local/lib /usr/lib /lib
libs=-lgdbm -ldb -ldl -lcrypt -lgdbm_compat
perllibs=-ldl -lcrypt
libc=/usr/lib/libc.a, so=dll, useshrplib=true, libperl=cygperl5_14.dll
gnulibc_version=  
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=dll, d_dlsymun=undef, ccdlflags=   
cccdlflags=   , lddlflags=  --shared  -Wl,--enable-auto-import -Wl,--export-                       all-symbols -Wl,--enable-auto-image-base -L/usr/local/lib -fstack-protector 


Characteristics of this binary (from libperl):
Compile-time options: MULTIPLICITY PERL_DONT_CREATE_GVSV
                    PERL_IMPLICIT_CONTEXT PERL_PRESERVE_IVUV
                    PERL_USE_SAFE_PUTENV USE_64_BIT_INT USE_ITHREADS
                    USE_LARGE_FILES USE_PERLIO USE_PERL_ATOF
                    USE_REENTRANT_API
 Locally applied patches:
    Bug#55162 File::Spec::case_tolerant performance
    CYG07 $vendorarch/auto/.rebase
    CYG15 static Win32CORE
    CYG17 cyg-1.7 paths-utf8
    0c612ce82 Fix building static extensions on cygwin, -UUSEIMPORTLIB
    1bac5ecc1 Fix 64-bit threading sv.c: S_anonymise_cv_maybe
    Cygwin::sync_winenv added
Built under cygwin
Compiled at Jul 12 2012 14:17:21
@INC:
/usr/lib/perl5/site_perl/5.14/i686-cygwin-threads-64int
/usr/lib/perl5/site_perl/5.14
/usr/lib/perl5/vendor_perl/5.14/i686-cygwin-threads-64int
/usr/lib/perl5/vendor_perl/5.14
/usr/lib/perl5/5.14/i686-cygwin-threads-64int
/usr/lib/perl5/5.14
/usr/lib/perl5/site_perl/5.10
/usr/lib/perl5/vendor_perl/5.10
/usr/lib/perl5/site_perl/5.8

http://sourceforge.net/mailarchive/message.php?msg_id=30388786 http://sourceforge.net/mailarchive/message.php?msg_id=30388786

The errors I get when I try to build XML::Sablotron (after perl makeFile.PL):

make[1]: Entering directory `/usr/src/XML-Sablotron-1.01/DOM 
make[1]: Leaving directory `/usr/src/XML-Sablotron-1.01/DOM 
make[1]: Entering directory `/usr/src/XML-Sablotron-1.01/Situation 
make[1]: Leaving directory `/usr/src/XML-Sablotron-1.01/Situation 
make[1]: Entering directory `/usr/src/XML-Sablotron-1.01/SXP 
make[1]: Leaving directory `/usr/src/XML-Sablotron-1.01/SXP 
make[1]: Entering directory `/usr/src/XML-Sablotron-1.01/Processor 
make[1]: Leaving directory `/usr/src/XML-Sablotron-1.01/Processor 
gcc-4 -c    -DPERL_USE_SAFE_PUTENV -U__STRICT_ANSI__ -g -fno-strict-aliasing -pipe -   fstack-protector -DUSEIMPORTLIB -O3    -DVERSION="1.01"  -DXS_VERSION="1.01"  "-I/usr/lib/perl5/5.14/i686-cygwin-threads-64int/CORE"  -DPERL_POLLUTE Sablotron.c
In file included from Sablotron.xs:88:0:
DOM/DOM.h: In Funktion »__createNodeOld«:
DOM/DOM.h:90:17: Warnung: Typkonvertierung von Zeiger auf Ganzzahl anderer Breite
In file included from Sablotron.xs:88:0:
DOM/DOM.h: In Funktion »__checkNodeInstanceData«:
DOM/DOM.h:120:22: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer Breite
DOM/DOM.h: In Funktion »__createNodeNew«:
DOM/DOM.h:153:5: Warnung: Typkonvertierung von Zeiger auf Ganzzahl anderer Breite
In file included from Sablotron.xs:89:0:
Processor/Processor.h: In Funktion »MessageHandlerMakeCodeStub«:
Processor/Processor.h:122:7: Fehler: »sv_undef« undeclared (first use in this function)
Processor/Processor.h:122:7: Anmerkung: each undeclared identifier is reported only     
once for each function it appears in
Processor/Processor.h: In Funktion »MessageHandlerLogStub«:
...
In file included from Sablotron.xs:91:0:
Situation/Situation.h: In Funktion »_SV2SXP_Node«:
Situation/Situation.h:113:19: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer     
Breite
./DOM/DOM.xsh: In Funktion »XS_XML__Sablotron__DOM_parse«:
./DOM/DOM.xsh:53:30: Warnung: Typkonvertierung in Zeiger von Ganzzahl anderer Breite
....
(the same error for Processor/Processor.xsh and Situation/Situation.xsh)

Surely the best way is to use not the Sablotron. But because of time, I would prefer not to change everything.

Answers

You just exhibited a very dangerous trait. You took an error such as:

Processor/Processor.h: In Funktion »MessageHandlerMakeCodeStub«:
Processor/Processor.h:122:7: Fehler: »sv_undef« undeclared

and made a series of unwarranted assumptions and arrived at the conclusions that 1) The problem is Cygwin and Windows specific; and 2) The problem is caused by the fact that perl is configured with use64bitint=define; and 3) The solution is to change integer sizes. (BTW, what s up with the mixture of German and English in error messages?)

http://search.cpan.org/perldoc/App%3a%3aperlbrew http://search.cpan.org/perldoc/App%3a%3aperlbrew

http://search.cpan.org/perldoc/ExtUtils%3a%3aMakeMaker http://search.cpan.org/perldoc/ExtUtils%3a%3aMakeMaker

POLLUTE Release 5.005 grandfathered old global symbol names by providing preprocessor macros for extension source compatibility. As of release 5.6, these preprocessor definitions are not available by default. The POLLUTE flag specifies that the old names should still be defined:
  perl Makefile.PL POLLUTE=1
 Please inform the module author if this is necessary to successfully install a module under 5.6 or later.

Unfortunately, that simple solution did not result in a successful build.

http://search.cpan.org/perldoc/Devel%3a%3aPPPort http://search.cpan.org/perldoc/Devel%3a%3aPPPort

http://markmail.org/message/lvgwrrxdkcgn2s3h http://markmail.org/message/lvgwrrxdkcgn2s3h

Source

License : cc by-sa 3.0

http://stackoverflow.com/questions/15769482/how-can-i-build-the-perl-extension-xmlsablotron

Related

Outils personnels
Espaces de noms

Variantes
Actions
Navigation
Outils