mirror of
https://github.com/macports/macports-ports.git
synced 2026-07-12 18:20:25 -07:00
46 lines
2.1 KiB
Diff
46 lines
2.1 KiB
Diff
Find dependencies using pkg-config. Fixes configure failure when using
|
|
libxslt 1.1.41 or later:
|
|
|
|
configure.ac:21: error: possibly undefined macro: AM_PATH_XSLT
|
|
|
|
https://github.com/rpeyron/libxmldiff/issues/7
|
|
https://github.com/rpeyron/libxmldiff/commit/ad965442f675dc0c045dd9c54d248a4a8560997f
|
|
https://github.com/rpeyron/libxmldiff/commit/36e6220aef124256b99c372501462f10a5df7963
|
|
--- configure.ac.orig 2020-05-09 14:28:29.000000000 -0500
|
|
+++ configure.ac 2025-02-28 18:06:34.000000000 -0600
|
|
@@ -17,10 +17,13 @@
|
|
AC_FUNC_VPRINTF
|
|
|
|
dnl libxml
|
|
-AM_PATH_XML2( 2.0.0, , AC_MSG_ERROR(libxml2 must be installed.) )
|
|
-AM_PATH_XSLT(,, AC_MSG_ERROR(libxslt must be installed.) )
|
|
+dnl AM_PATH_XML2( 2.0.0, , AC_MSG_ERROR(libxml2 must be installed.) )
|
|
+dnl AM_PATH_XSLT(,, AC_MSG_ERROR(libxslt must be installed.) )
|
|
dnl AC_CHECK_LIB(xslt, main, , AC_MSG_ERROR(libxslt must be installed.))
|
|
dnl AC_CHECK_LIB(exslt, main, , AC_MSG_ERROR(libexslt must be installed.))
|
|
+PKG_CHECK_MODULES(XML, libxml-2.0)
|
|
+PKG_CHECK_MODULES(XSLT, libxslt)
|
|
+PKG_CHECK_MODULES(EXSLT, libexslt)
|
|
|
|
dnl GCOV
|
|
|
|
@@ -54,11 +57,14 @@
|
|
AC_CHECK_PROGS(LCOV, lcov, false)
|
|
|
|
dnl Exports
|
|
+dnl a bug in libxml-2.0 pkg-config needs to include cflags in LIBS...
|
|
+dnl and pkg-config does not seem to declare CXXFLAGS or CPPFLAGS, so it may be redundant, but more will not harm
|
|
DEBUG="-g"
|
|
-LIBS="$DEBUG $LIBS $XML_LIBS $XSLT_LIBS -lexslt $GCOV_LIBS"
|
|
-CXXFLAGS="$DEBUG $CXXFLAGS $XML_CXXFLAGS $XSLT_CXXFLAGS $GCOV_CFLAGS"
|
|
-CPPFLAGS="$DEBUG $CPPFLAGS $XML_CPPFLAGS $XSLT_CPPFLAGS -Wno-write-strings $GCOV_CFLAGS"
|
|
-CFLAGS="$DEBUG $CFLAGS $XML_CFLAGS $XSLT_CFLAGS - -Wno-write-strings $GCOV_LIBS"
|
|
+LIBS="$DEBUG $LIBS $XML_LIBS $XML_CFLAGS $XSLT_LIBS $EXSLT_LIBS -lexslt $GCOV_LIBS"
|
|
+CXXFLAGS="$DEBUG $CXXFLAGS $XML_CXXFLAGS $XSLT_CXXFLAGS $EXSLT_CXXFLAGS $XML_CFLAGS $XSLT_CFLAGS $EXSLT_CFLAGS $GCOV_CFLAGS"
|
|
+CPPFLAGS="$DEBUG $CPPFLAGS $XML_CPPFLAGS $XSLT_CPPFLAGS $EXSLT_CPPFLAGS $XML_CFLAGS $XSLT_CFLAGS $EXSLT_CFLAGS -Wno-write-strings $GCOV_CFLAGS"
|
|
+CFLAGS="$DEBUG $CFLAGS $XML_CFLAGS $XSLT_CFLAGS $EXSLT_CFLAGS - -Wno-write-strings $GCOV_LIBS"
|
|
+
|
|
|
|
AC_OUTPUT( \
|
|
Makefile \
|