You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mxe/src/graphicsmagick-1-fix-xml2-c...

47 lines
1.6 KiB

This file is part of MXE. See LICENSE.md for licensing information.
This patch has been taken from:
https://sourceforge.net/p/graphicsmagick/bugs/154/
diff --git a/configure.ac b/configure.ac
index 979d2c4..12d4555 100755
--- a/configure.ac
+++ b/configure.ac
@@ -2373,12 +2373,13 @@ then
# Debian installs libxml headers under /usr/include/libxml2/libxml with
# the shared library installed under /usr/lib, whereas the package
# installs itself under $prefix/libxml and $prefix/lib.
- xml2_prefix=`xml2-config --prefix`
+ xml2_prefix=`"$xml2_config" --prefix`
if test -d "${xml2_prefix}/include/libxml2"
then
CPPFLAGS="$CPPFLAGS -I${xml2_prefix}/include/libxml2"
fi
LDFLAGS="$LDFLAGS -L${xml2_prefix}/lib"
+ LIBS="$LIBS `"$xml2_config" --libs`"
fi
failed=0
passed=0
@@ -2401,8 +2402,9 @@ then
LDFLAGS="$OLD_LDFLAGS"
CPPFLAGS="$OLD_CPPFLAGS"
else
- LIB_XML='-lxml2'
+ LIB_XML=`"$xml2_config" --libs`
LIBS="$LIB_XML $LIBS"
+ CPPFLAGS="$CPPFLAGS `"$xml2_config" --cflags`"
AC_DEFINE(HasXML,1,Define if you have XML library)
AC_MSG_RESULT(yes)
have_xml='yes'
diff --git a/magick/GraphicsMagick.pc.in b/magick/GraphicsMagick.pc.in
index 5757b37..87e3fd4 100644
--- a/magick/GraphicsMagick.pc.in
+++ b/magick/GraphicsMagick.pc.in
@@ -8,4 +8,6 @@ Name: GraphicsMagick
Version: @PACKAGE_VERSION@
Description: GraphicsMagick image processing library
+Requires.private: libxml-2.0
Libs: -L${libdir} -lGraphicsMagick
+Libs.private: @MAGICK_API_LDFLAGS@ @MAGICK_API_LIBS@
Cflags: -I${includedir} @MAGICK_API_PC_CPPFLAGS@