mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-26 02:01:03 +00:00
Update to use autoconf macro from libxml 2.2.10 distribution.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@8475 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
3186a534a7
commit
b323ba6b02
9 changed files with 398 additions and 195 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2001-01-04 Jonathan Gapen <jagapen@home.com>
|
||||||
|
|
||||||
|
* configure.in, aclocal.m4, acconfig.h: Replace libxml detection with
|
||||||
|
autoconf macro from libxml 2.2.10 installation.
|
||||||
|
* configure, Headers/gnustep/base/config.h.in: Regenerate.
|
||||||
|
* Headers/gnustep/base/GSXML.h, base/Source/GSXML.m,
|
||||||
|
base/Tools/gsdoc.m: Use proper libxml #includes.
|
||||||
|
|
||||||
2001-01-03 Adam Fedor <fedor@gnu.org>
|
2001-01-03 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
* configure.in: Change test for objc forwarding hook to match gcc
|
* configure.in: Change test for objc forwarding hook to match gcc
|
||||||
|
|
|
@ -31,13 +31,9 @@
|
||||||
#ifndef __GSXML_H__
|
#ifndef __GSXML_H__
|
||||||
#define __GSXML_H__
|
#define __GSXML_H__
|
||||||
|
|
||||||
#ifdef LIBXML2
|
/* libxml headers */
|
||||||
#include <libxml2/tree.h>
|
#include <tree.h>
|
||||||
#include <libxml2/entities.h>
|
#include <entities.h>
|
||||||
#else
|
|
||||||
#include <libxml/tree.h>
|
|
||||||
#include <libxml/entities.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <Foundation/NSObject.h>
|
#include <Foundation/NSObject.h>
|
||||||
#include <Foundation/NSString.h>
|
#include <Foundation/NSString.h>
|
||||||
|
|
|
@ -54,8 +54,8 @@
|
||||||
/* Define if using the ffcall library for invocations */
|
/* Define if using the ffcall library for invocations */
|
||||||
#undef USE_FFCALL
|
#undef USE_FFCALL
|
||||||
|
|
||||||
/* Define if the libxml header files are in libxml2 */
|
/* Define if libxml available */
|
||||||
#undef LIBXML2
|
#undef HAVE_LIBXML
|
||||||
|
|
||||||
/* The number of bytes in a double. */
|
/* The number of bytes in a double. */
|
||||||
#undef SIZEOF_DOUBLE
|
#undef SIZEOF_DOUBLE
|
||||||
|
|
|
@ -28,17 +28,11 @@
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#ifdef LIBXML2
|
/* libxml headers */
|
||||||
#include <libxml2/parser.h>
|
#include <parser.h>
|
||||||
#include <libxml2/parserInternals.h>
|
#include <parserInternals.h>
|
||||||
#include <libxml2/SAX.h>
|
#include <SAX.h>
|
||||||
#include <libxml2/HTMLparser.h>
|
#include <HTMLparser.h>
|
||||||
#else
|
|
||||||
#include <libxml/parser.h>
|
|
||||||
#include <libxml/parserInternals.h>
|
|
||||||
#include <libxml/SAX.h>
|
|
||||||
#include <libxml/HTMLparser.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <Foundation/GSXML.h>
|
#include <Foundation/GSXML.h>
|
||||||
#include <Foundation/NSData.h>
|
#include <Foundation/NSData.h>
|
||||||
|
|
|
@ -89,11 +89,7 @@ Parameters:
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#ifdef LIBXML2
|
#include <parser.h>
|
||||||
#include <libxml2/parser.h>
|
|
||||||
#else
|
|
||||||
#include <libxml/parser.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
NSString *pathExtension_GSDocRefs = @"gsdocrefs";
|
NSString *pathExtension_GSDocRefs = @"gsdocrefs";
|
||||||
NSString *pathExtension_GSDoc = @"gsdoc";
|
NSString *pathExtension_GSDoc = @"gsdoc";
|
||||||
|
|
|
@ -145,6 +145,6 @@
|
||||||
/* Define if using the ffcall library for invocations */
|
/* Define if using the ffcall library for invocations */
|
||||||
#undef USE_FFCALL
|
#undef USE_FFCALL
|
||||||
|
|
||||||
/* Define if the libxml header files are in libxml2 */
|
/* Define if libxml available */
|
||||||
#undef LIBXML2
|
#undef HAVE_LIBXML
|
||||||
|
|
||||||
|
|
152
aclocal.m4
vendored
152
aclocal.m4
vendored
|
@ -148,3 +148,155 @@ AC_SUBST(DYNAMIC_BUNDLER_LINKER)dnl
|
||||||
AC_SUBST(DYNAMIC_LDFLAGS)dnl
|
AC_SUBST(DYNAMIC_LDFLAGS)dnl
|
||||||
AC_SUBST(DYNAMIC_CFLAGS)dnl
|
AC_SUBST(DYNAMIC_CFLAGS)dnl
|
||||||
])
|
])
|
||||||
|
|
||||||
|
#-----------------------------------------------------------------------------
|
||||||
|
# Check for libxml; macro taken from libxml 2.2.10 installation
|
||||||
|
#-----------------------------------------------------------------------------
|
||||||
|
dnl Code shamelessly stolen from glib-config by Sebastian Rittau
|
||||||
|
dnl AM_PATH_XML([MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
|
||||||
|
AC_DEFUN(AM_PATH_XML,[
|
||||||
|
AC_ARG_WITH(xml-prefix,
|
||||||
|
[ --with-xml-prefix=PFX Prefix where libxml is installed (optional)],
|
||||||
|
xml_config_prefix="$withval", xml_config_prefix="")
|
||||||
|
AC_ARG_ENABLE(xmltest,
|
||||||
|
[ --disable-xmltest Do not try to compile and run a test XML program],,
|
||||||
|
enable_xmltest=yes)
|
||||||
|
|
||||||
|
if test x$xml_config_prefix != x ; then
|
||||||
|
xml_config_args="$xml_config_args --prefix=$xml_config_prefix"
|
||||||
|
if test x${XML_CONFIG+set} != xset ; then
|
||||||
|
XML_CONFIG=$xml_config_prefix/bin/xml-config
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_PATH_PROG(XML_CONFIG, xml-config, no)
|
||||||
|
min_xml_version=ifelse([$1], ,2.0.0, [$1])
|
||||||
|
AC_MSG_CHECKING(for libxml - version >= $min_xml_version)
|
||||||
|
no_xml=""
|
||||||
|
if test "$XML_CONFIG" = "no" ; then
|
||||||
|
no_xml=yes
|
||||||
|
else
|
||||||
|
XML_CFLAGS=`$XML_CONFIG $xml_config_args --cflags`
|
||||||
|
XML_LIBS=`$XML_CONFIG $xml_config_args --libs`
|
||||||
|
xml_config_major_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
|
||||||
|
xml_config_minor_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
|
||||||
|
xml_config_micro_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
|
||||||
|
if test "x$enable_xmltest" = "xyes" ; then
|
||||||
|
ac_save_CFLAGS="$CFLAGS"
|
||||||
|
ac_save_LIBS="$LIBS"
|
||||||
|
CFLAGS="$CFLAGS $XML_CFLAGS"
|
||||||
|
LIBS="$XML_LIBS $LIBS"
|
||||||
|
dnl
|
||||||
|
dnl Now check if the installed libxml is sufficiently new.
|
||||||
|
dnl
|
||||||
|
rm -f conf.xmltest
|
||||||
|
AC_TRY_RUN([
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <xmlversion.h>
|
||||||
|
#include <parser.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
main()
|
||||||
|
{
|
||||||
|
int xml_major_version, xml_minor_version, xml_micro_version;
|
||||||
|
int major, minor, micro;
|
||||||
|
char *tmp_version;
|
||||||
|
|
||||||
|
system("touch conf.xmltest");
|
||||||
|
|
||||||
|
tmp_version = xmlStrdup("$min_xml_version");
|
||||||
|
if(sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) {
|
||||||
|
printf("%s, bad version string\n", "$min_xml_version");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
tmp_version = xmlStrdup(LIBXML_DOTTED_VERSION);
|
||||||
|
if(sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) {
|
||||||
|
printf("%s, bad version string\n", "$min_xml_version");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if((xml_major_version != $xml_config_major_version) ||
|
||||||
|
(xml_minor_version != $xml_config_minor_version) ||
|
||||||
|
(xml_micro_version != $xml_config_micro_version))
|
||||||
|
{
|
||||||
|
printf("\n*** 'xml-config --version' returned %d.%d.%d, but libxml (%d.%d.%d)\n",
|
||||||
|
$xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version,
|
||||||
|
xml_major_version, xml_minor_version, xml_micro_version);
|
||||||
|
printf("*** was found! If xml-config was correct, then it is best\n");
|
||||||
|
printf("*** to remove the old version of libxml. You may also be able to fix the error\n");
|
||||||
|
printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
|
||||||
|
printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
|
||||||
|
printf("*** required on your system.\n");
|
||||||
|
printf("*** If xml-config was wrong, set the environment variable XML_CONFIG\n");
|
||||||
|
printf("*** to point to the correct copy of xml-config, and remove the file config.cache\n");
|
||||||
|
printf("*** before re-running configure\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if ((xml_major_version > major) ||
|
||||||
|
((xml_major_version == major) && (xml_minor_version > minor)) ||
|
||||||
|
((xml_major_version == major) && (xml_minor_version == minor) &&
|
||||||
|
(xml_micro_version >= micro)))
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
printf("\n*** An old version of libxml (%d.%d.%d) was found.\n",
|
||||||
|
xml_major_version, xml_minor_version, xml_micro_version);
|
||||||
|
printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n",
|
||||||
|
major, minor, micro);
|
||||||
|
printf("*** libxml is always available from ftp://ftp.gnome.org.\n");
|
||||||
|
printf("***\n");
|
||||||
|
printf("*** If you have already installed a sufficiently new version, this error\n");
|
||||||
|
printf("*** probably means that the wrong copy of the xml-config shell script is\n");
|
||||||
|
printf("*** being found. The easiest way to fix this is to remove the old version\n");
|
||||||
|
printf("*** of libxml, but you can also set the XML_CONFIG environment to point to the\n");
|
||||||
|
printf("*** correct copy of xml-config. (In this case, you will have to\n");
|
||||||
|
printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
|
||||||
|
printf("*** so that the correct libraries are found at run-time))\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
|
||||||
|
|
||||||
|
CFLAGS="$ac_save_CFLAGS"
|
||||||
|
LIBS="$ac_save_LIBS"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "x$no_xml" = x ; then
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
ifelse([$2], , :, [$2])
|
||||||
|
else
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
if test "$XML_CONFIG" = "no" ; then
|
||||||
|
echo "*** The xml-config script installed by libxml could not be found"
|
||||||
|
echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in"
|
||||||
|
echo "*** your path, or set the XML_CONFIG environment variable to the"
|
||||||
|
echo "*** full path to xml-config."
|
||||||
|
else
|
||||||
|
if test -f conf.xmltest ; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
echo "*** Could not run libxml test program, checking why..."
|
||||||
|
CFLAGS="$CFLAGS $XML_CFLAGS"
|
||||||
|
LIBS="$LIBS $XML_LIBS"
|
||||||
|
dnl FIXME: AC_TRY_LINK
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
XML_CFLAGS=""
|
||||||
|
XML_LIBS=""
|
||||||
|
ifelse([$3], , :, [$3])
|
||||||
|
fi
|
||||||
|
AC_SUBST(XML_CFLAGS)
|
||||||
|
AC_SUBST(XML_LIBS)
|
||||||
|
rm -f conf.xmltest
|
||||||
|
])
|
||||||
|
|
329
configure
vendored
329
configure
vendored
|
@ -20,9 +20,9 @@ ac_help="$ac_help
|
||||||
ac_help="$ac_help
|
ac_help="$ac_help
|
||||||
--enable-ffcall Enable use of ffcall library"
|
--enable-ffcall Enable use of ffcall library"
|
||||||
ac_help="$ac_help
|
ac_help="$ac_help
|
||||||
--with-libxml-include=PATH include path for libxml headers"
|
--with-xml-prefix=PFX Prefix where libxml is installed (optional)"
|
||||||
ac_help="$ac_help
|
ac_help="$ac_help
|
||||||
--with-libxml-library=PATH library path for libxml libraries"
|
--disable-xmltest Do not try to compile and run a test XML program"
|
||||||
ac_help="$ac_help
|
ac_help="$ac_help
|
||||||
--with-openssl-include=PATH include path for openssl headers"
|
--with-openssl-include=PATH include path for openssl headers"
|
||||||
ac_help="$ac_help
|
ac_help="$ac_help
|
||||||
|
@ -4507,128 +4507,228 @@ fi
|
||||||
|
|
||||||
|
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
# Check recent libxlm for Properytlists, GSXML, GSDoc etc.
|
# Check recent libxml for Properytlists, GSXML, GSDoc etc.
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
echo "Checking for libxml"
|
|
||||||
# Check whether --with-libxml-include or --without-libxml-include was given.
|
# Check whether --with-xml-prefix or --without-xml-prefix was given.
|
||||||
if test "${with_libxml_include+set}" = set; then
|
if test "${with_xml_prefix+set}" = set; then
|
||||||
withval="$with_libxml_include"
|
withval="$with_xml_prefix"
|
||||||
libxml_incdir="$withval"
|
xml_config_prefix="$withval"
|
||||||
else
|
else
|
||||||
libxml_incdir="no"
|
xml_config_prefix=""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check whether --enable-xmltest or --disable-xmltest was given.
|
||||||
# Check whether --with-libxml-library or --without-libxml-library was given.
|
if test "${enable_xmltest+set}" = set; then
|
||||||
if test "${with_libxml_library+set}" = set; then
|
enableval="$enable_xmltest"
|
||||||
withval="$with_libxml_library"
|
:
|
||||||
libxml_libdir="$withval"
|
|
||||||
else
|
else
|
||||||
libxml_libdir="no"
|
enable_xmltest=yes
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
cppflags_temp=$CFLAGS
|
if test x$xml_config_prefix != x ; then
|
||||||
libs_temp=$LIBS
|
xml_config_args="$xml_config_args --prefix=$xml_config_prefix"
|
||||||
|
if test x${XML_CONFIG+set} != xset ; then
|
||||||
|
XML_CONFIG=$xml_config_prefix/bin/xml-config
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
if test "$libxml_incdir" != "no"; then
|
# Extract the first word of "xml-config", so it can be a program name with args.
|
||||||
CPPFLAGS="$CPPFLAGS -I$libxml_incdir"
|
set dummy xml-config; ac_word=$2
|
||||||
fi
|
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||||
if test "$libxml_libdir" != "no"; then
|
echo "configure:4541: checking for $ac_word" >&5
|
||||||
LIBS="$LIBS -L$libxml_libdir"
|
if eval "test \"`echo '$''{'ac_cv_path_XML_CONFIG'+set}'`\" = set"; then
|
||||||
fi
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
|
|
||||||
xmlhdrdir=no
|
|
||||||
# The order of these tests is important.
|
|
||||||
cat > conftest.$ac_ext <<EOF
|
|
||||||
#line 4545 "configure"
|
|
||||||
#include "confdefs.h"
|
|
||||||
#include <libxml/xmlversion.h>
|
|
||||||
#if LIBXML_VERSION < 20203
|
|
||||||
#error libxml needs to be version 2.2.3 or later
|
|
||||||
#endif
|
|
||||||
EOF
|
|
||||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
|
||||||
{ (eval echo configure:4553: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
|
||||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
|
||||||
if test -z "$ac_err"; then
|
|
||||||
rm -rf conftest*
|
|
||||||
xmlhdrdir=libxml
|
|
||||||
else
|
else
|
||||||
echo "$ac_err" >&5
|
case "$XML_CONFIG" in
|
||||||
echo "configure: failed program was:" >&5
|
/*)
|
||||||
cat conftest.$ac_ext >&5
|
ac_cv_path_XML_CONFIG="$XML_CONFIG" # Let the user override the test with a path.
|
||||||
|
;;
|
||||||
|
?:/*)
|
||||||
|
ac_cv_path_XML_CONFIG="$XML_CONFIG" # Let the user override the test with a dos path.
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
||||||
|
ac_dummy="$PATH"
|
||||||
|
for ac_dir in $ac_dummy; do
|
||||||
|
test -z "$ac_dir" && ac_dir=.
|
||||||
|
if test -f $ac_dir/$ac_word; then
|
||||||
|
ac_cv_path_XML_CONFIG="$ac_dir/$ac_word"
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
IFS="$ac_save_ifs"
|
||||||
|
test -z "$ac_cv_path_XML_CONFIG" && ac_cv_path_XML_CONFIG="no"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
fi
|
fi
|
||||||
rm -f conftest*
|
XML_CONFIG="$ac_cv_path_XML_CONFIG"
|
||||||
if test $xmlhdrdir = no; then
|
if test -n "$XML_CONFIG"; then
|
||||||
cat > conftest.$ac_ext <<EOF
|
echo "$ac_t""$XML_CONFIG" 1>&6
|
||||||
#line 4566 "configure"
|
|
||||||
#include "confdefs.h"
|
|
||||||
#include <libxml2/xmlversion.h>
|
|
||||||
#if LIBXML_VERSION < 20203
|
|
||||||
#error libxml needs to be version 2.2.3 or later
|
|
||||||
#endif
|
|
||||||
EOF
|
|
||||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
|
||||||
{ (eval echo configure:4574: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
|
||||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
|
||||||
if test -z "$ac_err"; then
|
|
||||||
rm -rf conftest*
|
|
||||||
cat >> confdefs.h <<\EOF
|
|
||||||
#define LIBXML2 1
|
|
||||||
EOF
|
|
||||||
xmlhdrdir=libxml2
|
|
||||||
else
|
else
|
||||||
echo "$ac_err" >&5
|
echo "$ac_t""no" 1>&6
|
||||||
echo "configure: failed program was:" >&5
|
|
||||||
cat conftest.$ac_ext >&5
|
|
||||||
fi
|
fi
|
||||||
rm -f conftest*
|
|
||||||
fi
|
min_xml_version=2.2.3
|
||||||
echo "$ac_t""$xmlhdrdir" 1>&6
|
echo $ac_n "checking for libxml - version >= $min_xml_version""... $ac_c" 1>&6
|
||||||
if test $xmlhdrdir = no; then
|
echo "configure:4576: checking for libxml - version >= $min_xml_version" >&5
|
||||||
echo "Could not find libxml headers"
|
no_xml=""
|
||||||
echo "Check to make sure you have libxml version 2 or later installed"
|
if test "$XML_CONFIG" = "no" ; then
|
||||||
echo "configure: warning: Could not find libxml headers" 1>&2
|
no_xml=yes
|
||||||
HAVE_LIBXML=0
|
else
|
||||||
|
XML_CFLAGS=`$XML_CONFIG $xml_config_args --cflags`
|
||||||
|
XML_LIBS=`$XML_CONFIG $xml_config_args --libs`
|
||||||
|
xml_config_major_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
|
||||||
|
xml_config_minor_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
|
||||||
|
xml_config_micro_version=`$XML_CONFIG $xml_config_args --version | \
|
||||||
|
sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
|
||||||
|
if test "x$enable_xmltest" = "xyes" ; then
|
||||||
|
ac_save_CFLAGS="$CFLAGS"
|
||||||
|
ac_save_LIBS="$LIBS"
|
||||||
|
CFLAGS="$CFLAGS $XML_CFLAGS"
|
||||||
|
LIBS="$XML_LIBS $LIBS"
|
||||||
|
rm -f conf.xmltest
|
||||||
|
if test "$cross_compiling" = yes; then
|
||||||
|
echo $ac_n "cross compiling; assumed OK... $ac_c"
|
||||||
else
|
else
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4597 "configure"
|
#line 4599 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
#include "$xmlhdrdir/xmlversion.h"
|
|
||||||
#if LIBXML_VERSION < 20203
|
#include <stdlib.h>
|
||||||
#error
|
#include <stdio.h>
|
||||||
#endif
|
#include <xmlversion.h>
|
||||||
|
#include <parser.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
main()
|
||||||
|
{
|
||||||
|
int xml_major_version, xml_minor_version, xml_micro_version;
|
||||||
|
int major, minor, micro;
|
||||||
|
char *tmp_version;
|
||||||
|
|
||||||
|
system("touch conf.xmltest");
|
||||||
|
|
||||||
|
tmp_version = xmlStrdup("$min_xml_version");
|
||||||
|
if(sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) {
|
||||||
|
printf("%s, bad version string\n", "$min_xml_version");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
tmp_version = xmlStrdup(LIBXML_DOTTED_VERSION);
|
||||||
|
if(sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) {
|
||||||
|
printf("%s, bad version string\n", "$min_xml_version");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if((xml_major_version != $xml_config_major_version) ||
|
||||||
|
(xml_minor_version != $xml_config_minor_version) ||
|
||||||
|
(xml_micro_version != $xml_config_micro_version))
|
||||||
|
{
|
||||||
|
printf("\n*** 'xml-config --version' returned %d.%d.%d, but libxml (%d.%d.%d)\n",
|
||||||
|
$xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version,
|
||||||
|
xml_major_version, xml_minor_version, xml_micro_version);
|
||||||
|
printf("*** was found! If xml-config was correct, then it is best\n");
|
||||||
|
printf("*** to remove the old version of libxml. You may also be able to fix the error\n");
|
||||||
|
printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
|
||||||
|
printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
|
||||||
|
printf("*** required on your system.\n");
|
||||||
|
printf("*** If xml-config was wrong, set the environment variable XML_CONFIG\n");
|
||||||
|
printf("*** to point to the correct copy of xml-config, and remove the file config.cache\n");
|
||||||
|
printf("*** before re-running configure\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if ((xml_major_version > major) ||
|
||||||
|
((xml_major_version == major) && (xml_minor_version > minor)) ||
|
||||||
|
((xml_major_version == major) && (xml_minor_version == minor) &&
|
||||||
|
(xml_micro_version >= micro)))
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
printf("\n*** An old version of libxml (%d.%d.%d) was found.\n",
|
||||||
|
xml_major_version, xml_minor_version, xml_micro_version);
|
||||||
|
printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n",
|
||||||
|
major, minor, micro);
|
||||||
|
printf("*** libxml is always available from ftp://ftp.gnome.org.\n");
|
||||||
|
printf("***\n");
|
||||||
|
printf("*** If you have already installed a sufficiently new version, this error\n");
|
||||||
|
printf("*** probably means that the wrong copy of the xml-config shell script is\n");
|
||||||
|
printf("*** being found. The easiest way to fix this is to remove the old version\n");
|
||||||
|
printf("*** of libxml, but you can also set the XML_CONFIG environment to point to the\n");
|
||||||
|
printf("*** correct copy of xml-config. (In this case, you will have to\n");
|
||||||
|
printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
|
||||||
|
printf("*** so that the correct libraries are found at run-time))\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
if { (eval echo configure:4674: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||||
{ (eval echo configure:4605: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
then
|
||||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
:
|
||||||
if test -z "$ac_err"; then
|
|
||||||
rm -rf conftest*
|
|
||||||
libxml2plus=1
|
|
||||||
else
|
else
|
||||||
echo "$ac_err" >&5
|
|
||||||
echo "configure: failed program was:" >&5
|
echo "configure: failed program was:" >&5
|
||||||
cat conftest.$ac_ext >&5
|
cat conftest.$ac_ext >&5
|
||||||
rm -rf conftest*
|
rm -fr conftest*
|
||||||
libxml2plus=0
|
no_xml=yes
|
||||||
fi
|
fi
|
||||||
rm -f conftest*
|
rm -fr conftest*
|
||||||
if test $libxml2plus = 0; then
|
fi
|
||||||
echo "libxml version older than 2.2.3"
|
|
||||||
echo "configure: warning: libxml version older than 2.2.3" 1>&2
|
|
||||||
HAVE_LIBXML=0
|
CFLAGS="$ac_save_CFLAGS"
|
||||||
else
|
LIBS="$ac_save_LIBS"
|
||||||
HAVE_LIBXML=1
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "x$no_xml" = x ; then
|
||||||
|
echo "$ac_t""yes" 1>&6
|
||||||
|
enable_libxml=yes
|
||||||
|
else
|
||||||
|
echo "$ac_t""no" 1>&6
|
||||||
|
if test "$XML_CONFIG" = "no" ; then
|
||||||
|
echo "*** The xml-config script installed by libxml could not be found"
|
||||||
|
echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in"
|
||||||
|
echo "*** your path, or set the XML_CONFIG environment variable to the"
|
||||||
|
echo "*** full path to xml-config."
|
||||||
|
else
|
||||||
|
if test -f conf.xmltest ; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
echo "*** Could not run libxml test program, checking why..."
|
||||||
|
CFLAGS="$CFLAGS $XML_CFLAGS"
|
||||||
|
LIBS="$LIBS $XML_LIBS"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
XML_CFLAGS=""
|
||||||
|
XML_LIBS=""
|
||||||
|
enable_libxml=no
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
if test "$HAVE_LIBXML" = "0"; then
|
rm -f conf.xmltest
|
||||||
CPPFLAGS="$cppflags_temp";
|
|
||||||
LIBS="$libs_temp";
|
if test $enable_libxml = yes; then
|
||||||
|
CPPFLAGS="$CPPFLAGS $XML_CFLAGS"
|
||||||
|
LIBS="$LIBS $XML_LIBS"
|
||||||
|
HAVE_LIBXML=1
|
||||||
|
cat >> confdefs.h <<\EOF
|
||||||
|
#define HAVE_LIBXML 1
|
||||||
|
EOF
|
||||||
|
|
||||||
|
else
|
||||||
|
HAVE_LIBXML=0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
# Check OpenSSL for HTTPS support.
|
# Check OpenSSL for HTTPS support.
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
|
@ -4665,17 +4765,17 @@ for ac_hdr in openssl/ssl.h
|
||||||
do
|
do
|
||||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||||
echo "configure:4669: checking for $ac_hdr" >&5
|
echo "configure:4769: checking for $ac_hdr" >&5
|
||||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||||
echo $ac_n "(cached) $ac_c" 1>&6
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
else
|
else
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4674 "configure"
|
#line 4774 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
#include <$ac_hdr>
|
#include <$ac_hdr>
|
||||||
EOF
|
EOF
|
||||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||||
{ (eval echo configure:4679: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
{ (eval echo configure:4779: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||||
if test -z "$ac_err"; then
|
if test -z "$ac_err"; then
|
||||||
rm -rf conftest*
|
rm -rf conftest*
|
||||||
|
@ -4707,7 +4807,7 @@ if test $ac_cv_header_openssl_ssl_h = no; then
|
||||||
echo "configure: warning: Could not find openssl headers" 1>&2
|
echo "configure: warning: Could not find openssl headers" 1>&2
|
||||||
else
|
else
|
||||||
echo $ac_n "checking for CRYPTO_malloc in -lcrypto""... $ac_c" 1>&6
|
echo $ac_n "checking for CRYPTO_malloc in -lcrypto""... $ac_c" 1>&6
|
||||||
echo "configure:4711: checking for CRYPTO_malloc in -lcrypto" >&5
|
echo "configure:4811: checking for CRYPTO_malloc in -lcrypto" >&5
|
||||||
ac_lib_var=`echo crypto'_'CRYPTO_malloc | sed 'y%./+-%__p_%'`
|
ac_lib_var=`echo crypto'_'CRYPTO_malloc | sed 'y%./+-%__p_%'`
|
||||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||||
echo $ac_n "(cached) $ac_c" 1>&6
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
|
@ -4715,7 +4815,7 @@ else
|
||||||
ac_save_LIBS="$LIBS"
|
ac_save_LIBS="$LIBS"
|
||||||
LIBS="-lcrypto $LIBS"
|
LIBS="-lcrypto $LIBS"
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4719 "configure"
|
#line 4819 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
/* Override any gcc2 internal prototype to avoid an error. */
|
/* Override any gcc2 internal prototype to avoid an error. */
|
||||||
/* We use char because int might match the return type of a gcc2
|
/* We use char because int might match the return type of a gcc2
|
||||||
|
@ -4726,7 +4826,7 @@ int main() {
|
||||||
CRYPTO_malloc()
|
CRYPTO_malloc()
|
||||||
; return 0; }
|
; return 0; }
|
||||||
EOF
|
EOF
|
||||||
if { (eval echo configure:4730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
if { (eval echo configure:4830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||||
rm -rf conftest*
|
rm -rf conftest*
|
||||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||||
else
|
else
|
||||||
|
@ -4751,7 +4851,7 @@ fi
|
||||||
base_libs="$LIBS"
|
base_libs="$LIBS"
|
||||||
LIBS="$LIBS -lcrypto"
|
LIBS="$LIBS -lcrypto"
|
||||||
echo $ac_n "checking for ssl2_clear in -lssl""... $ac_c" 1>&6
|
echo $ac_n "checking for ssl2_clear in -lssl""... $ac_c" 1>&6
|
||||||
echo "configure:4755: checking for ssl2_clear in -lssl" >&5
|
echo "configure:4855: checking for ssl2_clear in -lssl" >&5
|
||||||
ac_lib_var=`echo ssl'_'ssl2_clear | sed 'y%./+-%__p_%'`
|
ac_lib_var=`echo ssl'_'ssl2_clear | sed 'y%./+-%__p_%'`
|
||||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||||
echo $ac_n "(cached) $ac_c" 1>&6
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
|
@ -4759,7 +4859,7 @@ else
|
||||||
ac_save_LIBS="$LIBS"
|
ac_save_LIBS="$LIBS"
|
||||||
LIBS="-lssl $LIBS"
|
LIBS="-lssl $LIBS"
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4763 "configure"
|
#line 4863 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
/* Override any gcc2 internal prototype to avoid an error. */
|
/* Override any gcc2 internal prototype to avoid an error. */
|
||||||
/* We use char because int might match the return type of a gcc2
|
/* We use char because int might match the return type of a gcc2
|
||||||
|
@ -4770,7 +4870,7 @@ int main() {
|
||||||
ssl2_clear()
|
ssl2_clear()
|
||||||
; return 0; }
|
; return 0; }
|
||||||
EOF
|
EOF
|
||||||
if { (eval echo configure:4774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
if { (eval echo configure:4874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||||
rm -rf conftest*
|
rm -rf conftest*
|
||||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||||
else
|
else
|
||||||
|
@ -4845,17 +4945,17 @@ for ac_hdr in gmp.h
|
||||||
do
|
do
|
||||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||||
echo "configure:4849: checking for $ac_hdr" >&5
|
echo "configure:4949: checking for $ac_hdr" >&5
|
||||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||||
echo $ac_n "(cached) $ac_c" 1>&6
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
else
|
else
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4854 "configure"
|
#line 4954 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
#include <$ac_hdr>
|
#include <$ac_hdr>
|
||||||
EOF
|
EOF
|
||||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||||
{ (eval echo configure:4859: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
{ (eval echo configure:4959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||||
if test -z "$ac_err"; then
|
if test -z "$ac_err"; then
|
||||||
rm -rf conftest*
|
rm -rf conftest*
|
||||||
|
@ -4887,7 +4987,7 @@ if test $ac_cv_header_gmp_h = no; then
|
||||||
echo "configure: warning: Could not find gmp headers" 1>&2
|
echo "configure: warning: Could not find gmp headers" 1>&2
|
||||||
else
|
else
|
||||||
echo $ac_n "checking for mpf_abs in -lgmp""... $ac_c" 1>&6
|
echo $ac_n "checking for mpf_abs in -lgmp""... $ac_c" 1>&6
|
||||||
echo "configure:4891: checking for mpf_abs in -lgmp" >&5
|
echo "configure:4991: checking for mpf_abs in -lgmp" >&5
|
||||||
ac_lib_var=`echo gmp'_'mpf_abs | sed 'y%./+-%__p_%'`
|
ac_lib_var=`echo gmp'_'mpf_abs | sed 'y%./+-%__p_%'`
|
||||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||||
echo $ac_n "(cached) $ac_c" 1>&6
|
echo $ac_n "(cached) $ac_c" 1>&6
|
||||||
|
@ -4895,7 +4995,7 @@ else
|
||||||
ac_save_LIBS="$LIBS"
|
ac_save_LIBS="$LIBS"
|
||||||
LIBS="-lgmp $LIBS"
|
LIBS="-lgmp $LIBS"
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 4899 "configure"
|
#line 4999 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
/* Override any gcc2 internal prototype to avoid an error. */
|
/* Override any gcc2 internal prototype to avoid an error. */
|
||||||
/* We use char because int might match the return type of a gcc2
|
/* We use char because int might match the return type of a gcc2
|
||||||
|
@ -4906,7 +5006,7 @@ int main() {
|
||||||
mpf_abs()
|
mpf_abs()
|
||||||
; return 0; }
|
; return 0; }
|
||||||
EOF
|
EOF
|
||||||
if { (eval echo configure:4910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
if { (eval echo configure:5010: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||||
rm -rf conftest*
|
rm -rf conftest*
|
||||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||||
else
|
else
|
||||||
|
@ -5156,6 +5256,9 @@ s%@DYNAMIC_LINKER@%$DYNAMIC_LINKER%g
|
||||||
s%@GS_PASS_ARGUMENTS@%$GS_PASS_ARGUMENTS%g
|
s%@GS_PASS_ARGUMENTS@%$GS_PASS_ARGUMENTS%g
|
||||||
s%@GS_FAKE_MAIN@%$GS_FAKE_MAIN%g
|
s%@GS_FAKE_MAIN@%$GS_FAKE_MAIN%g
|
||||||
s%@WITH_FFI@%$WITH_FFI%g
|
s%@WITH_FFI@%$WITH_FFI%g
|
||||||
|
s%@XML_CONFIG@%$XML_CONFIG%g
|
||||||
|
s%@XML_CFLAGS@%$XML_CFLAGS%g
|
||||||
|
s%@XML_LIBS@%$XML_LIBS%g
|
||||||
s%@HAVE_LIBXML@%$HAVE_LIBXML%g
|
s%@HAVE_LIBXML@%$HAVE_LIBXML%g
|
||||||
s%@HAVE_GMP@%$HAVE_GMP%g
|
s%@HAVE_GMP@%$HAVE_GMP%g
|
||||||
s%@whole_archive@%$whole_archive%g
|
s%@whole_archive@%$whole_archive%g
|
||||||
|
|
62
configure.in
62
configure.in
|
@ -818,65 +818,19 @@ fi
|
||||||
AC_SUBST(WITH_FFI)
|
AC_SUBST(WITH_FFI)
|
||||||
|
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
# Check recent libxlm for Properytlists, GSXML, GSDoc etc.
|
# Check recent libxml for Properytlists, GSXML, GSDoc etc.
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
echo "Checking for libxml"
|
AM_PATH_XML(2.2.3, enable_libxml=yes, enable_libxml=no)
|
||||||
AC_ARG_WITH(libxml-include,
|
if test $enable_libxml = yes; then
|
||||||
[ --with-libxml-include=PATH include path for libxml headers],
|
CPPFLAGS="$CPPFLAGS $XML_CFLAGS"
|
||||||
libxml_incdir="$withval", libxml_incdir="no")
|
LIBS="$LIBS $XML_LIBS"
|
||||||
|
|
||||||
AC_ARG_WITH(libxml-library,
|
|
||||||
[ --with-libxml-library=PATH library path for libxml libraries],
|
|
||||||
libxml_libdir="$withval", libxml_libdir="no")
|
|
||||||
|
|
||||||
cppflags_temp=$CFLAGS
|
|
||||||
libs_temp=$LIBS
|
|
||||||
|
|
||||||
if test "$libxml_incdir" != "no"; then
|
|
||||||
CPPFLAGS="$CPPFLAGS -I$libxml_incdir"
|
|
||||||
fi
|
|
||||||
if test "$libxml_libdir" != "no"; then
|
|
||||||
LIBS="$LIBS -L$libxml_libdir"
|
|
||||||
fi
|
|
||||||
|
|
||||||
xmlhdrdir=no
|
|
||||||
# The order of these tests is important.
|
|
||||||
AC_TRY_CPP([#include <libxml/xmlversion.h>
|
|
||||||
#if LIBXML_VERSION < 20203
|
|
||||||
#error libxml needs to be version 2.2.3 or later
|
|
||||||
#endif], xmlhdrdir=libxml)
|
|
||||||
if test $xmlhdrdir = no; then
|
|
||||||
AC_TRY_CPP([#include <libxml2/xmlversion.h>
|
|
||||||
#if LIBXML_VERSION < 20203
|
|
||||||
#error libxml needs to be version 2.2.3 or later
|
|
||||||
#endif], AC_DEFINE(LIBXML2) xmlhdrdir=libxml2)
|
|
||||||
fi
|
|
||||||
AC_MSG_RESULT($xmlhdrdir)
|
|
||||||
if test $xmlhdrdir = no; then
|
|
||||||
echo "Could not find libxml headers"
|
|
||||||
echo "Check to make sure you have libxml version 2 or later installed"
|
|
||||||
AC_MSG_WARN(Could not find libxml headers)
|
|
||||||
HAVE_LIBXML=0
|
|
||||||
else
|
|
||||||
AC_TRY_CPP([#include "$xmlhdrdir/xmlversion.h"
|
|
||||||
#if LIBXML_VERSION < 20203
|
|
||||||
#error
|
|
||||||
#endif], libxml2plus=1, libxml2plus=0)
|
|
||||||
if test $libxml2plus = 0; then
|
|
||||||
echo "libxml version older than 2.2.3"
|
|
||||||
AC_MSG_WARN(libxml version older than 2.2.3)
|
|
||||||
HAVE_LIBXML=0
|
|
||||||
else
|
|
||||||
HAVE_LIBXML=1
|
HAVE_LIBXML=1
|
||||||
fi
|
AC_DEFINE(HAVE_LIBXML)
|
||||||
|
else
|
||||||
|
HAVE_LIBXML=0
|
||||||
fi
|
fi
|
||||||
AC_SUBST(HAVE_LIBXML)
|
AC_SUBST(HAVE_LIBXML)
|
||||||
|
|
||||||
if test "$HAVE_LIBXML" = "0"; then
|
|
||||||
CPPFLAGS="$cppflags_temp";
|
|
||||||
LIBS="$libs_temp";
|
|
||||||
fi
|
|
||||||
|
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
# Check OpenSSL for HTTPS support.
|
# Check OpenSSL for HTTPS support.
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in a new issue