Re: [xml] MSYS and MINGW: undefined reference to _imp__xmlFree
- From: Igor Zlatkovic <igor zlatkovic com>
- To: xml gnome org
- Subject: Re: [xml] MSYS and MINGW: undefined reference to _imp__xmlFree
- Date: Mon, 09 Nov 2009 00:40:00 +0100
On 08/11/09 19:08, Roumen Petrov wrote:
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
http://git.gnome.org/cgit/libxml2/commit/?id=a194ccb8d19ddde94c2c04ddf197e6a629f7cc9b
, i.e. restored "...defined(IN_LIBXML)..." plus following patch
Sure, clear as sky. When no clouds are lingering. Sorry, when that
commit was discussed, Daniel did alert me and I have seen the patch and
in my then obviously thorough blindness I have missed the significance.
That can never work because it breaks the import/export of variables.
xmlMalloc is a variable (a pointer to a function).
==========================================
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);
#endif
#endif
#endif
+#ifndef PIC
+# define LIBXML_STATIC
+#endif
#endif /* ! __XML_LIBXML_H__ */
==========================================
xsltproc work again.
That should be okay. PIC will have no meaning for MSVC and the user will
still have to define LIBXML_STATIC herself, but that is how it was before.
Ciao,
Igor
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]