summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-07-04 02:36:13 +0300
committerAndrei Karas <akaras@inbox.ru>2017-07-04 02:36:13 +0300
commit12fca1585909b971a57ec4b376d6a5257e345595 (patch)
tree97d1b84f3c82473bd43e709965512fb10ecca61d /configure.ac
parentb9a19970d29d8c586b931a4ff9d1f4013a001e62 (diff)
downloadmanaplus-12fca1585909b971a57ec4b376d6a5257e345595.tar.gz
manaplus-12fca1585909b971a57ec4b376d6a5257e345595.tar.bz2
manaplus-12fca1585909b971a57ec4b376d6a5257e345595.tar.xz
manaplus-12fca1585909b971a57ec4b376d6a5257e345595.zip
Add possible workaround into configure for broken libxml2 or/and icu.
Some icu versions allow only C++11 compilation, but libxml2 not adding this flags.
Diffstat (limited to 'configure.ac')
-rwxr-xr-xconfigure.ac15
1 files changed, 13 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 143f0c0e0..1da07677c 100755
--- a/configure.ac
+++ b/configure.ac
@@ -193,6 +193,7 @@ AC_TYPE_SSIZE_T
# Search for *-config
AC_PATH_PROG(PKG_CONFIG, pkg-config)
AC_PATH_PROG(CURL_CONFIG, curl-config)
+AC_PATH_PROG(ICU_CONFIG, icu-config)
LIBS="$LIBS `$PKG_CONFIG --libs zlib`"
CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags zlib`"
@@ -398,8 +399,18 @@ if test "$xmllib" == "libxml"; then
AC_CHECK_LIB([xml2], [xmlInitParser], ,
AC_MSG_ERROR([ *** Unable to find libxml2 library (http://xmlsoft.org/)]))
fi
- AC_CHECK_HEADERS([libxml/xmlreader.h], ,
- AC_MSG_ERROR([ *** libxml2 library found but cannot find headers (http://xmlsoft.org/)]))
+ AC_CHECK_HEADERS(
+ [libxml/xmlreader.h],
+ ,
+ CPPFLAGS="$CPPFLAGS `$ICU_CONFIG --cxxflags`"
+ AC_MSG_RESULT([no])
+ AC_MSG_CHECKING([Checking libxml2 headers with icu bug fix])
+ AC_CHECK_HEADERS(
+ [libxml/xmlreader.h],
+ ,
+ AC_MSG_ERROR([ *** libxml2 library found but cannot find headers (http://xmlsoft.org/)])
+ )
+ )
fi
if test "$xmllib" == "pugixml"; then