[xml] " __imp__xmlFree" when cross-compiling libxml2 with mingw on linux



Hi,

I'm trying to cross-compile libxml2 on linux (Ubuntu Gutsy) with mingw, without
success. I would be very important to get it working, because I'm trying to get
a full cross-build-chain to compile the gnome stack, in order to use it as a
depolyment platform on Windows also.

Tried to google around, but not found any working solution. Any help
would be very
appreciated!

Configure parameters are:

--enable-static=yes --enable-shared=no --without-threads --without-python
--without-ftp --without-http --without-readline --disable-ipv6

but I get this error (the same with libxml2-2.6.27 and libxml2-2.6.30):

==========================================================================
xmllint.o:xmllint.c:(.text+0xdf): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x253): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x384): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x470): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x47a): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x484): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x4b3): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x4bd): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x565): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x578): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x736): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x740): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x7a4): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x7ae): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x7f3): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x7fd): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x861): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x86e): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x8aa): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x8bd): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x921): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x92b): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x973): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x97d): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x9f1): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x9fe): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0xa3a): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0xa4d): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x1e28): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x237c): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x2386): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x23e4): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x23ee): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x2498): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x24a2): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x24d3): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x24dd): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x296b): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x2975): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x3154): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x3167): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x34f6): undefined reference to `__imp__xmlFree'
xmllint.o:xmllint.c:(.text+0x36a3): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x36ad): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x3a04): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x3a12): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x3c10): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x3c23): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x41bf): undefined reference to
`__imp__xmlTreeIndentString'
xmllint.o:xmllint.c:(.text+0x41f1): undefined reference to
`__imp__xmlLoadExtDtdDefaultValue'
xmllint.o:xmllint.c:(.text+0x4202): undefined reference to
`__imp__xmlLoadExtDtdDefaultValue'
xmllint.o:xmllint.c:(.text+0x4222): undefined reference to
`__imp__xmlDoValidityCheckingDefaultValue'
xmllint.o:xmllint.c:(.text+0x4261): undefined reference to
`__imp__xmlLoadExtDtdDefaultValue'
xmllint.o:xmllint.c:(.text+0x42e9): undefined reference to
`__imp__xmlLoadExtDtdDefaultValue'
xmllint.o:xmllint.c:(.text+0x48a8): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x48b2): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x48e8): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x48f2): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4902): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x490c): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4925): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x492f): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4948): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x4952): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4997): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x49a1): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x49d0): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x49da): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4a39): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x4a43): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4a86): undefined reference to
`__imp__xmlGenericErrorContext'
xmllint.o:xmllint.c:(.text+0x4a90): undefined reference to
`__imp__xmlGenericError'
xmllint.o:xmllint.c:(.text+0x4c08): undefined reference to
`__imp__xmlParserVersion'
xmllint.o:xmllint.c:(.text+0x58a0): undefined reference to
`__imp__xmlGetWarningsDefaultValue'
xmllint.o:xmllint.c:(.text+0x58e4): undefined reference to
`__imp__xmlGetWarningsDefaultValue'
xmllint.o:xmllint.c:(.text+0x5931): undefined reference to
`__imp__xmlParserDebugEntities'
=============================================================

Last command is:

make[2]: Entering directory `/home/guido/checkout/libxml2-2.6.27'
/bin/bash ./libtool --tag=CC --mode=link /usr/bin/i586-mingw32msvc-gcc  -O2
-mno-cygwin -mms-bitfields -mwindows -march=i686 -I/home/guido/target/include
-pedantic -W -Wformat -Wunused -Wimplicit -Wreturn-type -Wswitch -Wcomment
-Wtrigraphs -Wformat -Wchar-subscripts -Wuninitialized -Wparentheses -Wshadow
-Wpointer-arith -Wcast-align -Wwrite-strings -Waggregate-return
-Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline
-Wredundant-decls  -mno-cygwin -L/home/guido/target/lib  -o xmllint.exe
xmllint.o ./libxml2.la   -liconv -lm
/usr/bin/i586-mingw32msvc-gcc -O2 -mno-cygwin -mms-bitfields -mwindows
-march=i686 -I/home/guido/target/include -pedantic -W -Wformat -Wunused
-Wimplicit -Wreturn-type -Wswitch -Wcomment -Wtrigraphs -Wformat
-Wchar-subscripts -Wuninitialized -Wparentheses -Wshadow -Wpointer-arith
-Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes
-Wmissing-prototypes -Wnested-externs -Winline -Wredundant-decls -mno-cygwin -o
xmllint.exe xmllint.o  -L/home/guido/target/lib ./.libs/libxml2.a
/home/guido/target/lib/libiconv.dll.a -lm   -Wl,--rpath
-Wl,/home/guido/target/lib -Wl,--rpath -Wl,/home/guido/target/lib

Thanks,
Guido



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]