Re: [xml] MSYS and MINGW: undefined reference to _imp__xmlFree

Thanks Martin !!!

Roumen Petrov wrote:
Martin Schlemmer wrote:

It seems to me Martin is right but proposed patch is not correct to me. I think that code has to set LIBXML_STATIC internally when is compiled for static library. As libxml build is libtool based we may use PIC definition. libtool when compile source for shared always set -DPIC .


I've cross-build libxml, libxslt , xmlsec with code from repository but
xmlsec application crash. My investigation show that application crash
when code call xmlMalloc. Also I found that xsltproc crash too.

Now with reverted commit
, i.e. restored "...defined(IN_LIBXML)..." plus following patch
diff --git a/libxml.h b/libxml.h
index 3c44c83..1656ac2 100644
--- a/libxml.h
+++ b/libxml.h
@@ -90,4 +90,7 @@ void __xmlGlobalInitMutexDestroy(void);
+#ifndef PIC
+#  define LIBXML_STATIC
 #endif /* ! __XML_LIBXML_H__ */

xsltproc work again.


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