... | ... |
@@ -318,7 +318,6 @@ VERSION = @VERSION@ |
318 | 318 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
319 | 319 |
WERR_CFLAGS = @WERR_CFLAGS@ |
320 | 320 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
321 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
322 | 321 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
323 | 322 |
XML_LIBS = @XML_LIBS@ |
324 | 323 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -20,195 +20,6 @@ You have another version of autoconf. It may work, but is not guaranteed to. |
20 | 20 |
If you have problems, you may need to regenerate the build system entirely. |
21 | 21 |
To do so, use the procedure documented by the package, typically `autoreconf'.])]) |
22 | 22 |
|
23 |
-# Configure paths for LIBXML2 |
|
24 |
-# Mike Hommey 2004-06-19 |
|
25 |
-# use CPPFLAGS instead of CFLAGS |
|
26 |
-# Toshio Kuratomi 2001-04-21 |
|
27 |
-# Adapted from: |
|
28 |
-# Configure paths for GLIB |
|
29 |
-# Owen Taylor 97-11-3 |
|
30 |
- |
|
31 |
-dnl AM_PATH_XML2([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) |
|
32 |
-dnl Test for XML, and define XML_CPPFLAGS and XML_LIBS |
|
33 |
-dnl |
|
34 |
-AC_DEFUN([AM_PATH_XML2],[ |
|
35 |
-AC_ARG_WITH(xml-prefix, |
|
36 |
- [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], |
|
37 |
- xml_config_prefix="$withval", xml_config_prefix="") |
|
38 |
-AC_ARG_WITH(xml-exec-prefix, |
|
39 |
- [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], |
|
40 |
- xml_config_exec_prefix="$withval", xml_config_exec_prefix="") |
|
41 |
-AC_ARG_ENABLE(xmltest, |
|
42 |
- [ --disable-xmltest Do not try to compile and run a test LIBXML program],, |
|
43 |
- enable_xmltest=yes) |
|
44 |
- |
|
45 |
- if test x$xml_config_exec_prefix != x ; then |
|
46 |
- xml_config_args="$xml_config_args" |
|
47 |
- if test x${XML2_CONFIG+set} != xset ; then |
|
48 |
- XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config |
|
49 |
- fi |
|
50 |
- fi |
|
51 |
- if test x$xml_config_prefix != x ; then |
|
52 |
- xml_config_args="$xml_config_args --prefix=$xml_config_prefix" |
|
53 |
- if test x${XML2_CONFIG+set} != xset ; then |
|
54 |
- XML2_CONFIG=$xml_config_prefix/bin/xml2-config |
|
55 |
- fi |
|
56 |
- fi |
|
57 |
- |
|
58 |
- AC_PATH_PROG(XML2_CONFIG, xml2-config, no) |
|
59 |
- min_xml_version=ifelse([$1], ,2.0.0,[$1]) |
|
60 |
- AC_MSG_CHECKING(for libxml - version >= $min_xml_version) |
|
61 |
- no_xml="" |
|
62 |
- if test "$XML2_CONFIG" = "no" ; then |
|
63 |
- no_xml=yes |
|
64 |
- else |
|
65 |
- XML_CPPFLAGS=`$XML2_CONFIG $xml_config_args --cflags` |
|
66 |
- XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` |
|
67 |
- xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
68 |
- sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` |
|
69 |
- xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
70 |
- sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` |
|
71 |
- xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
72 |
- sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` |
|
73 |
- if test "x$enable_xmltest" = "xyes" ; then |
|
74 |
- ac_save_CPPFLAGS="$CPPFLAGS" |
|
75 |
- ac_save_LIBS="$LIBS" |
|
76 |
- CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS" |
|
77 |
- LIBS="$XML_LIBS $LIBS" |
|
78 |
-dnl |
|
79 |
-dnl Now check if the installed libxml is sufficiently new. |
|
80 |
-dnl (Also sanity checks the results of xml2-config to some extent) |
|
81 |
-dnl |
|
82 |
- rm -f conf.xmltest |
|
83 |
- AC_TRY_RUN([ |
|
84 |
-#include <stdlib.h> |
|
85 |
-#include <stdio.h> |
|
86 |
-#include <string.h> |
|
87 |
-#include <libxml/xmlversion.h> |
|
88 |
- |
|
89 |
-int |
|
90 |
-main() |
|
91 |
-{ |
|
92 |
- int xml_major_version, xml_minor_version, xml_micro_version; |
|
93 |
- int major, minor, micro; |
|
94 |
- char *tmp_version; |
|
95 |
- |
|
96 |
- system("touch conf.xmltest"); |
|
97 |
- |
|
98 |
- /* Capture xml2-config output via autoconf/configure variables */ |
|
99 |
- /* HP/UX 9 (%@#!) writes to sscanf strings */ |
|
100 |
- tmp_version = (char *)strdup("$min_xml_version"); |
|
101 |
- if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { |
|
102 |
- printf("%s, bad version string from xml2-config\n", "$min_xml_version"); |
|
103 |
- exit(1); |
|
104 |
- } |
|
105 |
- free(tmp_version); |
|
106 |
- |
|
107 |
- /* Capture the version information from the header files */ |
|
108 |
- tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); |
|
109 |
- if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { |
|
110 |
- printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); |
|
111 |
- exit(1); |
|
112 |
- } |
|
113 |
- free(tmp_version); |
|
114 |
- |
|
115 |
- /* Compare xml2-config output to the libxml headers */ |
|
116 |
- if ((xml_major_version != $xml_config_major_version) || |
|
117 |
- (xml_minor_version != $xml_config_minor_version) || |
|
118 |
- (xml_micro_version != $xml_config_micro_version)) |
|
119 |
- { |
|
120 |
- printf("*** libxml header files (version %d.%d.%d) do not match\n", |
|
121 |
- xml_major_version, xml_minor_version, xml_micro_version); |
|
122 |
- printf("*** xml2-config (version %d.%d.%d)\n", |
|
123 |
- $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); |
|
124 |
- return 1; |
|
125 |
- } |
|
126 |
-/* Compare the headers to the library to make sure we match */ |
|
127 |
- /* Less than ideal -- doesn't provide us with return value feedback, |
|
128 |
- * only exits if there's a serious mismatch between header and library. |
|
129 |
- */ |
|
130 |
- LIBXML_TEST_VERSION; |
|
131 |
- |
|
132 |
- /* Test that the library is greater than our minimum version */ |
|
133 |
- if ((xml_major_version > major) || |
|
134 |
- ((xml_major_version == major) && (xml_minor_version > minor)) || |
|
135 |
- ((xml_major_version == major) && (xml_minor_version == minor) && |
|
136 |
- (xml_micro_version >= micro))) |
|
137 |
- { |
|
138 |
- return 0; |
|
139 |
- } |
|
140 |
- else |
|
141 |
- { |
|
142 |
- printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", |
|
143 |
- xml_major_version, xml_minor_version, xml_micro_version); |
|
144 |
- printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", |
|
145 |
- major, minor, micro); |
|
146 |
- printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); |
|
147 |
- printf("***\n"); |
|
148 |
- printf("*** If you have already installed a sufficiently new version, this error\n"); |
|
149 |
- printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); |
|
150 |
- printf("*** being found. The easiest way to fix this is to remove the old version\n"); |
|
151 |
- printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); |
|
152 |
- printf("*** correct copy of xml2-config. (In this case, you will have to\n"); |
|
153 |
- printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); |
|
154 |
- printf("*** so that the correct libraries are found at run-time))\n"); |
|
155 |
- } |
|
156 |
- return 1; |
|
157 |
-} |
|
158 |
-],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) |
|
159 |
- CPPFLAGS="$ac_save_CPPFLAGS" |
|
160 |
- LIBS="$ac_save_LIBS" |
|
161 |
- fi |
|
162 |
- fi |
|
163 |
- |
|
164 |
- if test "x$no_xml" = x ; then |
|
165 |
- AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) |
|
166 |
- ifelse([$2], , :, [$2]) |
|
167 |
- else |
|
168 |
- AC_MSG_RESULT(no) |
|
169 |
- if test "$XML2_CONFIG" = "no" ; then |
|
170 |
- echo "*** The xml2-config script installed by LIBXML could not be found" |
|
171 |
- echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" |
|
172 |
- echo "*** your path, or set the XML2_CONFIG environment variable to the" |
|
173 |
- echo "*** full path to xml2-config." |
|
174 |
- else |
|
175 |
- if test -f conf.xmltest ; then |
|
176 |
- : |
|
177 |
- else |
|
178 |
- echo "*** Could not run libxml test program, checking why..." |
|
179 |
- CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS" |
|
180 |
- LIBS="$LIBS $XML_LIBS" |
|
181 |
- AC_TRY_LINK([ |
|
182 |
-#include <libxml/xmlversion.h> |
|
183 |
-#include <stdio.h> |
|
184 |
-], [ LIBXML_TEST_VERSION; return 0;], |
|
185 |
- [ echo "*** The test program compiled, but did not run. This usually means" |
|
186 |
- echo "*** that the run-time linker is not finding LIBXML or finding the wrong" |
|
187 |
- echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" |
|
188 |
- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" |
|
189 |
- echo "*** to the installed location Also, make sure you have run ldconfig if that" |
|
190 |
- echo "*** is required on your system" |
|
191 |
- echo "***" |
|
192 |
- echo "*** If you have an old version installed, it is best to remove it, although" |
|
193 |
- echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], |
|
194 |
- [ echo "*** The test program failed to compile or link. See the file config.log for the" |
|
195 |
- echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" |
|
196 |
- echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" |
|
197 |
- echo "*** may want to edit the xml2-config script: $XML2_CONFIG" ]) |
|
198 |
- CPPFLAGS="$ac_save_CPPFLAGS" |
|
199 |
- LIBS="$ac_save_LIBS" |
|
200 |
- fi |
|
201 |
- fi |
|
202 |
- |
|
203 |
- XML_CPPFLAGS="" |
|
204 |
- XML_LIBS="" |
|
205 |
- ifelse([$3], , :, [$3]) |
|
206 |
- fi |
|
207 |
- AC_SUBST(XML_CPPFLAGS) |
|
208 |
- AC_SUBST(XML_LIBS) |
|
209 |
- rm -f conf.xmltest |
|
210 |
-]) |
|
211 |
- |
|
212 | 23 |
# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008, 2011 Free Software |
213 | 24 |
# Foundation, Inc. |
214 | 25 |
# |
... | ... |
@@ -287,7 +287,6 @@ VERSION = @VERSION@ |
287 | 287 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
288 | 288 |
WERR_CFLAGS = @WERR_CFLAGS@ |
289 | 289 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
290 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
291 | 290 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
292 | 291 |
XML_LIBS = @XML_LIBS@ |
293 | 292 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -223,7 +223,6 @@ VERSION = @VERSION@ |
223 | 223 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
224 | 224 |
WERR_CFLAGS = @WERR_CFLAGS@ |
225 | 225 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
226 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
227 | 226 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
228 | 227 |
XML_LIBS = @XML_LIBS@ |
229 | 228 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -241,7 +241,6 @@ VERSION = @VERSION@ |
241 | 241 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
242 | 242 |
WERR_CFLAGS = @WERR_CFLAGS@ |
243 | 243 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
244 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
245 | 244 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
246 | 245 |
XML_LIBS = @XML_LIBS@ |
247 | 246 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -254,7 +254,6 @@ VERSION = @VERSION@ |
254 | 254 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
255 | 255 |
WERR_CFLAGS = @WERR_CFLAGS@ |
256 | 256 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
257 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
258 | 257 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
259 | 258 |
XML_LIBS = @XML_LIBS@ |
260 | 259 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -252,7 +252,6 @@ VERSION = @VERSION@ |
252 | 252 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
253 | 253 |
WERR_CFLAGS = @WERR_CFLAGS@ |
254 | 254 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
255 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
256 | 255 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
257 | 256 |
XML_LIBS = @XML_LIBS@ |
258 | 257 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -258,7 +258,6 @@ VERSION = @VERSION@ |
258 | 258 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
259 | 259 |
WERR_CFLAGS = @WERR_CFLAGS@ |
260 | 260 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
261 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
262 | 261 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
263 | 262 |
XML_LIBS = @XML_LIBS@ |
264 | 263 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -243,7 +243,6 @@ VERSION = @VERSION@ |
243 | 243 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
244 | 244 |
WERR_CFLAGS = @WERR_CFLAGS@ |
245 | 245 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
246 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
247 | 246 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
248 | 247 |
XML_LIBS = @XML_LIBS@ |
249 | 248 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -668,9 +668,6 @@ CFGDIR |
668 | 668 |
DBDIR |
669 | 669 |
XML_LIBS |
670 | 670 |
XML_CPPFLAGS |
671 |
-XML2_CONFIG |
|
672 |
-ENABLE_XML_FALSE |
|
673 |
-ENABLE_XML_TRUE |
|
674 | 671 |
ENABLE_UNRAR_FALSE |
675 | 672 |
ENABLE_UNRAR_TRUE |
676 | 673 |
LIBBZ2_PREFIX |
... | ... |
@@ -860,9 +857,7 @@ enable_bzip2 |
860 | 860 |
with_libbz2_prefix |
861 | 861 |
enable_unrar |
862 | 862 |
enable_xml |
863 |
-with_xml_prefix |
|
864 |
-with_xml_exec_prefix |
|
865 |
-enable_xmltest |
|
863 |
+with_xml |
|
866 | 864 |
enable_getaddrinfo |
867 | 865 |
enable_ipv6 |
868 | 866 |
enable_dns |
... | ... |
@@ -1542,7 +1537,6 @@ Optional Features: |
1542 | 1542 |
--disable-bzip2 disable bzip2 support |
1543 | 1543 |
--disable-unrar do not build libclamunrar and libclamunrar_iface |
1544 | 1544 |
--disable-xml disable DMG and XAR support |
1545 |
- --disable-xmltest Do not try to compile and run a test LIBXML program |
|
1546 | 1545 |
--disable-getaddrinfo disable support for getaddrinfo |
1547 | 1546 |
--disable-ipv6 disable IPv6 support |
1548 | 1547 |
--disable-dns disable support for database verification through |
... | ... |
@@ -1585,8 +1579,8 @@ Optional Packages: |
1585 | 1585 |
/usr/local or /usr if not found in /usr/local) |
1586 | 1586 |
--with-libbz2-prefix[=DIR] search for libbz2 in DIR/include and DIR/lib |
1587 | 1587 |
--without-libbz2-prefix don't search for libbz2 in includedir and libdir |
1588 |
- --with-xml-prefix=PFX Prefix where libxml is installed (optional) |
|
1589 |
- --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional) |
|
1588 |
+ --with-xml=DIR path to directory containing libxml2 library (default= |
|
1589 |
+ /usr/local or /usr if not found in /usr/local) |
|
1590 | 1590 |
--with-iconv supports iconv() (default=auto) |
1591 | 1591 |
--with-user=uid name of the clamav user (default=clamav) |
1592 | 1592 |
--with-group=gid name of the clamav group (default=clamav) |
... | ... |
@@ -17001,298 +16995,180 @@ else |
17001 | 17001 |
fi |
17002 | 17002 |
|
17003 | 17003 |
|
17004 |
-want_xml="yes" |
|
17004 |
+want_xml="auto" |
|
17005 | 17005 |
# Check whether --enable-xml was given. |
17006 | 17006 |
if test "${enable_xml+set}" = set; then : |
17007 | 17007 |
enableval=$enable_xml; want_xml=$enableval |
17008 | 17008 |
else |
17009 |
- want_xml="yes" |
|
17009 |
+ want_xml="auto" |
|
17010 | 17010 |
fi |
17011 | 17011 |
|
17012 |
- if test "$want_xml" = "yes"; then |
|
17013 |
- ENABLE_XML_TRUE= |
|
17014 |
- ENABLE_XML_FALSE='#' |
|
17015 |
-else |
|
17016 |
- ENABLE_XML_TRUE='#' |
|
17017 |
- ENABLE_XML_FALSE= |
|
17018 |
-fi |
|
17019 |
- |
|
17020 |
- |
|
17021 |
-if test "$want_xml" = "yes" |
|
17022 |
-then |
|
17023 |
- |
|
17024 |
- |
|
17025 |
-# Check whether --with-xml-prefix was given. |
|
17026 |
-if test "${with_xml_prefix+set}" = set; then : |
|
17027 |
- withval=$with_xml_prefix; xml_config_prefix="$withval" |
|
17028 |
-else |
|
17029 |
- xml_config_prefix="" |
|
17030 |
-fi |
|
17031 |
- |
|
17032 |
- |
|
17033 |
-# Check whether --with-xml-exec-prefix was given. |
|
17034 |
-if test "${with_xml_exec_prefix+set}" = set; then : |
|
17035 |
- withval=$with_xml_exec_prefix; xml_config_exec_prefix="$withval" |
|
17036 |
-else |
|
17037 |
- xml_config_exec_prefix="" |
|
17038 |
-fi |
|
17039 |
- |
|
17040 |
-# Check whether --enable-xmltest was given. |
|
17041 |
-if test "${enable_xmltest+set}" = set; then : |
|
17042 |
- enableval=$enable_xmltest; |
|
17043 |
-else |
|
17044 |
- enable_xmltest=yes |
|
17045 |
-fi |
|
17046 | 17012 |
|
17013 |
+working_xml="no" |
|
17014 |
+if test "$want_xml" != "no"; then |
|
17015 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml2 installation" >&5 |
|
17016 |
+$as_echo_n "checking for libxml2 installation... " >&6; } |
|
17047 | 17017 |
|
17048 |
- if test x$xml_config_exec_prefix != x ; then |
|
17049 |
- xml_config_args="$xml_config_args" |
|
17050 |
- if test x${XML2_CONFIG+set} != xset ; then |
|
17051 |
- XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config |
|
17052 |
- fi |
|
17053 |
- fi |
|
17054 |
- if test x$xml_config_prefix != x ; then |
|
17055 |
- xml_config_args="$xml_config_args --prefix=$xml_config_prefix" |
|
17056 |
- if test x${XML2_CONFIG+set} != xset ; then |
|
17057 |
- XML2_CONFIG=$xml_config_prefix/bin/xml2-config |
|
17058 |
- fi |
|
17018 |
+# Check whether --with-xml was given. |
|
17019 |
+if test "${with_xml+set}" = set; then : |
|
17020 |
+ withval=$with_xml; |
|
17021 |
+ if test "$withval" |
|
17022 |
+ then |
|
17023 |
+ XML_HOME="$withval" |
|
17024 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $XML_HOME" >&5 |
|
17025 |
+$as_echo "using $XML_HOME" >&6; } |
|
17059 | 17026 |
fi |
17060 | 17027 |
|
17061 |
- # Extract the first word of "xml2-config", so it can be a program name with args. |
|
17062 |
-set dummy xml2-config; ac_word=$2 |
|
17063 |
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
|
17064 |
-$as_echo_n "checking for $ac_word... " >&6; } |
|
17065 |
-if ${ac_cv_path_XML2_CONFIG+:} false; then : |
|
17066 |
- $as_echo_n "(cached) " >&6 |
|
17067 | 17028 |
else |
17068 |
- case $XML2_CONFIG in |
|
17069 |
- [\\/]* | ?:[\\/]*) |
|
17070 |
- ac_cv_path_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test with a path. |
|
17071 |
- ;; |
|
17072 |
- *) |
|
17073 |
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
|
17074 |
-for as_dir in $PATH |
|
17075 |
-do |
|
17076 |
- IFS=$as_save_IFS |
|
17077 |
- test -z "$as_dir" && as_dir=. |
|
17078 |
- for ac_exec_ext in '' $ac_executable_extensions; do |
|
17079 |
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
|
17080 |
- ac_cv_path_XML2_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
|
17081 |
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
|
17082 |
- break 2 |
|
17029 |
+ |
|
17030 |
+ XML_HOME=/usr/local |
|
17031 |
+ if test ! -f "$XML_HOME/include/libxml/xmlreader.h" |
|
17032 |
+ then |
|
17033 |
+ XML_HOME=/usr |
|
17083 | 17034 |
fi |
17084 |
-done |
|
17085 |
- done |
|
17086 |
-IFS=$as_save_IFS |
|
17035 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML_HOME" >&5 |
|
17036 |
+$as_echo "$XML_HOME" >&6; } |
|
17087 | 17037 |
|
17088 |
- test -z "$ac_cv_path_XML2_CONFIG" && ac_cv_path_XML2_CONFIG="no" |
|
17089 |
- ;; |
|
17090 |
-esac |
|
17091 |
-fi |
|
17092 |
-XML2_CONFIG=$ac_cv_path_XML2_CONFIG |
|
17093 |
-if test -n "$XML2_CONFIG"; then |
|
17094 |
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5 |
|
17095 |
-$as_echo "$XML2_CONFIG" >&6; } |
|
17096 |
-else |
|
17097 |
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
|
17098 |
-$as_echo "no" >&6; } |
|
17099 | 17038 |
fi |
17100 | 17039 |
|
17101 | 17040 |
|
17102 |
- min_xml_version=2.5.0 |
|
17103 |
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml - version >= $min_xml_version" >&5 |
|
17104 |
-$as_echo_n "checking for libxml - version >= $min_xml_version... " >&6; } |
|
17105 |
- no_xml="" |
|
17106 |
- if test "$XML2_CONFIG" = "no" ; then |
|
17107 |
- no_xml=yes |
|
17041 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ****** checking XML_HOME $XML_HOME ******" >&5 |
|
17042 |
+$as_echo "$as_me: WARNING: ****** checking XML_HOME $XML_HOME ******" >&2;} |
|
17043 |
+ |
|
17044 |
+ if test ! -f "$XML_HOME/include/libxml2/libxml/xmlreader.h"; then |
|
17045 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ****** not found, cannot test ******" >&5 |
|
17046 |
+$as_echo "$as_me: WARNING: ****** not found, cannot test ******" >&2;} |
|
17047 |
+ if test "$want_xml" = "yes"; then |
|
17048 |
+ as_fn_error $? "Please install libxml2 packages" "$LINENO" 5 |
|
17049 |
+ fi |
|
17108 | 17050 |
else |
17109 |
- XML_CPPFLAGS=`$XML2_CONFIG $xml_config_args --cflags` |
|
17110 |
- XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` |
|
17111 |
- xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
17112 |
- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` |
|
17113 |
- xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
17114 |
- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` |
|
17115 |
- xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ |
|
17116 |
- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` |
|
17117 |
- if test "x$enable_xmltest" = "xyes" ; then |
|
17118 |
- ac_save_CPPFLAGS="$CPPFLAGS" |
|
17119 |
- ac_save_LIBS="$LIBS" |
|
17120 |
- CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS" |
|
17121 |
- LIBS="$XML_LIBS $LIBS" |
|
17122 |
- rm -f conf.xmltest |
|
17123 |
- if test "$cross_compiling" = yes; then : |
|
17124 |
- echo $ac_n "cross compiling; assumed OK... $ac_c" |
|
17051 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ****** found, testing ******" >&5 |
|
17052 |
+$as_echo "$as_me: WARNING: ****** found, testing ******" >&2;} |
|
17053 |
+ save_LIBS="$LIBS" |
|
17054 |
+ if test "$XML_HOME" != "/usr"; then |
|
17055 |
+ save_CPPFLAGS="$CPPFLAGS" |
|
17056 |
+ CPPFLAGS="$CPPFLAGS -I$XML_HOME/include" |
|
17057 |
+ save_LDFLAGS="$LDFLAGS" |
|
17058 |
+ LDFLAGS="$LDFLAGS -Wl,-rpath $XML_HOME/lib" |
|
17059 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlTextReaderRead in -lxml2" >&5 |
|
17060 |
+$as_echo_n "checking for xmlTextReaderRead in -lxml2... " >&6; } |
|
17061 |
+if ${ac_cv_lib_xml2_xmlTextReaderRead+:} false; then : |
|
17062 |
+ $as_echo_n "(cached) " >&6 |
|
17125 | 17063 |
else |
17126 |
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
17064 |
+ ac_check_lib_save_LIBS=$LIBS |
|
17065 |
+LIBS="-lxml2 $LIBS" |
|
17066 |
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
17127 | 17067 |
/* end confdefs.h. */ |
17128 | 17068 |
|
17129 |
-#include <stdlib.h> |
|
17130 |
-#include <stdio.h> |
|
17131 |
-#include <string.h> |
|
17132 |
-#include <libxml/xmlversion.h> |
|
17133 |
- |
|
17069 |
+/* Override any GCC internal prototype to avoid an error. |
|
17070 |
+ Use char because int might match the return type of a GCC |
|
17071 |
+ builtin and then its argument prototype would still apply. */ |
|
17072 |
+#ifdef __cplusplus |
|
17073 |
+extern "C" |
|
17074 |
+#endif |
|
17075 |
+char xmlTextReaderRead (); |
|
17134 | 17076 |
int |
17135 |
-main() |
|
17077 |
+main () |
|
17136 | 17078 |
{ |
17137 |
- int xml_major_version, xml_minor_version, xml_micro_version; |
|
17138 |
- int major, minor, micro; |
|
17139 |
- char *tmp_version; |
|
17140 |
- |
|
17141 |
- system("touch conf.xmltest"); |
|
17142 |
- |
|
17143 |
- /* Capture xml2-config output via autoconf/configure variables */ |
|
17144 |
- /* HP/UX 9 (%@#!) writes to sscanf strings */ |
|
17145 |
- tmp_version = (char *)strdup("$min_xml_version"); |
|
17146 |
- if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { |
|
17147 |
- printf("%s, bad version string from xml2-config\n", "$min_xml_version"); |
|
17148 |
- exit(1); |
|
17149 |
- } |
|
17150 |
- free(tmp_version); |
|
17151 |
- |
|
17152 |
- /* Capture the version information from the header files */ |
|
17153 |
- tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); |
|
17154 |
- if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { |
|
17155 |
- printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); |
|
17156 |
- exit(1); |
|
17157 |
- } |
|
17158 |
- free(tmp_version); |
|
17159 |
- |
|
17160 |
- /* Compare xml2-config output to the libxml headers */ |
|
17161 |
- if ((xml_major_version != $xml_config_major_version) || |
|
17162 |
- (xml_minor_version != $xml_config_minor_version) || |
|
17163 |
- (xml_micro_version != $xml_config_micro_version)) |
|
17164 |
- { |
|
17165 |
- printf("*** libxml header files (version %d.%d.%d) do not match\n", |
|
17166 |
- xml_major_version, xml_minor_version, xml_micro_version); |
|
17167 |
- printf("*** xml2-config (version %d.%d.%d)\n", |
|
17168 |
- $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); |
|
17169 |
- return 1; |
|
17170 |
- } |
|
17171 |
-/* Compare the headers to the library to make sure we match */ |
|
17172 |
- /* Less than ideal -- doesn't provide us with return value feedback, |
|
17173 |
- * only exits if there's a serious mismatch between header and library. |
|
17174 |
- */ |
|
17175 |
- LIBXML_TEST_VERSION; |
|
17176 |
- |
|
17177 |
- /* Test that the library is greater than our minimum version */ |
|
17178 |
- if ((xml_major_version > major) || |
|
17179 |
- ((xml_major_version == major) && (xml_minor_version > minor)) || |
|
17180 |
- ((xml_major_version == major) && (xml_minor_version == minor) && |
|
17181 |
- (xml_micro_version >= micro))) |
|
17182 |
- { |
|
17183 |
- return 0; |
|
17184 |
- } |
|
17185 |
- else |
|
17186 |
- { |
|
17187 |
- printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", |
|
17188 |
- xml_major_version, xml_minor_version, xml_micro_version); |
|
17189 |
- printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", |
|
17190 |
- major, minor, micro); |
|
17191 |
- printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); |
|
17192 |
- printf("***\n"); |
|
17193 |
- printf("*** If you have already installed a sufficiently new version, this error\n"); |
|
17194 |
- printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); |
|
17195 |
- printf("*** being found. The easiest way to fix this is to remove the old version\n"); |
|
17196 |
- printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); |
|
17197 |
- printf("*** correct copy of xml2-config. (In this case, you will have to\n"); |
|
17198 |
- printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); |
|
17199 |
- printf("*** so that the correct libraries are found at run-time))\n"); |
|
17200 |
- } |
|
17201 |
- return 1; |
|
17079 |
+return xmlTextReaderRead (); |
|
17080 |
+ ; |
|
17081 |
+ return 0; |
|
17202 | 17082 |
} |
17203 |
- |
|
17204 | 17083 |
_ACEOF |
17205 |
-if ac_fn_c_try_run "$LINENO"; then : |
|
17206 |
- |
|
17084 |
+if ac_fn_c_try_link "$LINENO"; then : |
|
17085 |
+ ac_cv_lib_xml2_xmlTextReaderRead=yes |
|
17207 | 17086 |
else |
17208 |
- no_xml=yes |
|
17087 |
+ ac_cv_lib_xml2_xmlTextReaderRead=no |
|
17209 | 17088 |
fi |
17210 |
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
|
17211 |
- conftest.$ac_objext conftest.beam conftest.$ac_ext |
|
17089 |
+rm -f core conftest.err conftest.$ac_objext \ |
|
17090 |
+ conftest$ac_exeext conftest.$ac_ext |
|
17091 |
+LIBS=$ac_check_lib_save_LIBS |
|
17092 |
+fi |
|
17093 |
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlTextReaderRead" >&5 |
|
17094 |
+$as_echo "$ac_cv_lib_xml2_xmlTextReaderRead" >&6; } |
|
17095 |
+if test "x$ac_cv_lib_xml2_xmlTextReaderRead" = xyes; then : |
|
17096 |
+ working_xml="yes";XML_CPPFLAGS="-I/usr/include/libxml2";XML_LIBS="-Wl,-rpath $XML_HOME/lib -lxml2" |
|
17097 |
+else |
|
17098 |
+ working_xml="no" |
|
17212 | 17099 |
fi |
17213 | 17100 |
|
17214 |
- CPPFLAGS="$ac_save_CPPFLAGS" |
|
17215 |
- LIBS="$ac_save_LIBS" |
|
17216 |
- fi |
|
17217 |
- fi |
|
17218 |
- |
|
17219 |
- if test "x$no_xml" = x ; then |
|
17220 |
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)" >&5 |
|
17221 |
-$as_echo "yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)" >&6; } |
|
17222 |
- : |
|
17223 |
- else |
|
17224 |
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
|
17225 |
-$as_echo "no" >&6; } |
|
17226 |
- if test "$XML2_CONFIG" = "no" ; then |
|
17227 |
- echo "*** The xml2-config script installed by LIBXML could not be found" |
|
17228 |
- echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" |
|
17229 |
- echo "*** your path, or set the XML2_CONFIG environment variable to the" |
|
17230 |
- echo "*** full path to xml2-config." |
|
17231 |
- else |
|
17232 |
- if test -f conf.xmltest ; then |
|
17233 |
- : |
|
17234 |
- else |
|
17235 |
- echo "*** Could not run libxml test program, checking why..." |
|
17236 |
- CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS" |
|
17237 |
- LIBS="$LIBS $XML_LIBS" |
|
17238 |
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
17101 |
+ CPPFLAGS="$save_CPPFLAGS" |
|
17102 |
+ LDFLAGS="$save_LDFLAGS" |
|
17103 |
+ else |
|
17104 |
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlTextReaderRead in -lxml2" >&5 |
|
17105 |
+$as_echo_n "checking for xmlTextReaderRead in -lxml2... " >&6; } |
|
17106 |
+if ${ac_cv_lib_xml2_xmlTextReaderRead+:} false; then : |
|
17107 |
+ $as_echo_n "(cached) " >&6 |
|
17108 |
+else |
|
17109 |
+ ac_check_lib_save_LIBS=$LIBS |
|
17110 |
+LIBS="-lxml2 $LIBS" |
|
17111 |
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
17239 | 17112 |
/* end confdefs.h. */ |
17240 | 17113 |
|
17241 |
-#include <libxml/xmlversion.h> |
|
17242 |
-#include <stdio.h> |
|
17243 |
- |
|
17114 |
+/* Override any GCC internal prototype to avoid an error. |
|
17115 |
+ Use char because int might match the return type of a GCC |
|
17116 |
+ builtin and then its argument prototype would still apply. */ |
|
17117 |
+#ifdef __cplusplus |
|
17118 |
+extern "C" |
|
17119 |
+#endif |
|
17120 |
+char xmlTextReaderRead (); |
|
17244 | 17121 |
int |
17245 | 17122 |
main () |
17246 | 17123 |
{ |
17247 |
- LIBXML_TEST_VERSION; return 0; |
|
17124 |
+return xmlTextReaderRead (); |
|
17248 | 17125 |
; |
17249 | 17126 |
return 0; |
17250 | 17127 |
} |
17251 | 17128 |
_ACEOF |
17252 | 17129 |
if ac_fn_c_try_link "$LINENO"; then : |
17253 |
- echo "*** The test program compiled, but did not run. This usually means" |
|
17254 |
- echo "*** that the run-time linker is not finding LIBXML or finding the wrong" |
|
17255 |
- echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" |
|
17256 |
- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" |
|
17257 |
- echo "*** to the installed location Also, make sure you have run ldconfig if that" |
|
17258 |
- echo "*** is required on your system" |
|
17259 |
- echo "***" |
|
17260 |
- echo "*** If you have an old version installed, it is best to remove it, although" |
|
17261 |
- echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" |
|
17262 |
-else |
|
17263 |
- echo "*** The test program failed to compile or link. See the file config.log for the" |
|
17264 |
- echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" |
|
17265 |
- echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" |
|
17266 |
- echo "*** may want to edit the xml2-config script: $XML2_CONFIG" |
|
17130 |
+ ac_cv_lib_xml2_xmlTextReaderRead=yes |
|
17131 |
+else |
|
17132 |
+ ac_cv_lib_xml2_xmlTextReaderRead=no |
|
17267 | 17133 |
fi |
17268 | 17134 |
rm -f core conftest.err conftest.$ac_objext \ |
17269 | 17135 |
conftest$ac_exeext conftest.$ac_ext |
17270 |
- CPPFLAGS="$ac_save_CPPFLAGS" |
|
17271 |
- LIBS="$ac_save_LIBS" |
|
17272 |
- fi |
|
17273 |
- fi |
|
17136 |
+LIBS=$ac_check_lib_save_LIBS |
|
17137 |
+fi |
|
17138 |
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlTextReaderRead" >&5 |
|
17139 |
+$as_echo "$ac_cv_lib_xml2_xmlTextReaderRead" >&6; } |
|
17140 |
+if test "x$ac_cv_lib_xml2_xmlTextReaderRead" = xyes; then : |
|
17141 |
+ working_xml="yes";XML_CPPFLAGS="-I/usr/include/libxml2";XML_LIBS="-lxml2" |
|
17142 |
+else |
|
17143 |
+ working_xml="no" |
|
17144 |
+fi |
|
17274 | 17145 |
|
17275 |
- XML_CPPFLAGS="" |
|
17276 |
- XML_LIBS="" |
|
17277 |
- : |
|
17146 |
+ fi |
|
17147 |
+ LIBS="$save_LIBS" |
|
17278 | 17148 |
fi |
17149 |
+fi |
|
17150 |
+ |
|
17151 |
+if test "$working_xml" = "yes"; then |
|
17279 | 17152 |
|
17153 |
+$as_echo "#define HAVE_LIBXML2 1" >>confdefs.h |
|
17280 | 17154 |
|
17281 |
- rm -f conf.xmltest |
|
17155 |
+ |
|
17156 |
+$as_echo "#define ENABLE_XML 1" >>confdefs.h |
|
17282 | 17157 |
|
17283 | 17158 |
|
17284 |
-$as_echo "#define HAVE_LIBXML2 1" >>confdefs.h |
|
17285 | 17159 |
|
17286 | 17160 |
else |
17287 |
- XML_CPPFLAGS="" |
|
17288 |
- XML_LIBS="" |
|
17161 |
+ if test "$want_xml" = "yes"; then |
|
17162 |
+ as_fn_error $? "Please install libxml2 packages" "$LINENO" 5 |
|
17163 |
+ fi |
|
17164 |
+ XML_CPPFLAGS="" |
|
17165 |
+ XML_LIBS="" |
|
17289 | 17166 |
|
17290 | 17167 |
|
17291 | 17168 |
|
17292 | 17169 |
$as_echo "#define HAVE_LIBXML2 0" >>confdefs.h |
17293 | 17170 |
|
17171 |
+ |
|
17172 |
+$as_echo "#define ENABLE_XML 0" >>confdefs.h |
|
17173 |
+ |
|
17294 | 17174 |
fi |
17295 | 17175 |
|
17176 |
+ |
|
17177 |
+ |
|
17296 | 17178 |
# Check whether --enable-getaddrinfo was given. |
17297 | 17179 |
if test "${enable_getaddrinfo+set}" = set; then : |
17298 | 17180 |
enableval=$enable_getaddrinfo; want_getaddrinfo=$enableval |
... | ... |
@@ -21417,10 +21293,6 @@ if test -z "${ENABLE_UNRAR_TRUE}" && test -z "${ENABLE_UNRAR_FALSE}"; then |
21417 | 21417 |
as_fn_error $? "conditional \"ENABLE_UNRAR\" was never defined. |
21418 | 21418 |
Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
21419 | 21419 |
fi |
21420 |
-if test -z "${ENABLE_XML_TRUE}" && test -z "${ENABLE_XML_FALSE}"; then |
|
21421 |
- as_fn_error $? "conditional \"ENABLE_XML\" was never defined. |
|
21422 |
-Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
|
21423 |
-fi |
|
21424 | 21420 |
if test -z "${BUILD_CLAMD_TRUE}" && test -z "${BUILD_CLAMD_FALSE}"; then |
21425 | 21421 |
as_fn_error $? "conditional \"BUILD_CLAMD\" was never defined. |
21426 | 21422 |
Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
... | ... |
@@ -24029,10 +23901,6 @@ if test -z "${ENABLE_UNRAR_TRUE}" && test -z "${ENABLE_UNRAR_FALSE}"; then |
24029 | 24029 |
as_fn_error $? "conditional \"ENABLE_UNRAR\" was never defined. |
24030 | 24030 |
Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
24031 | 24031 |
fi |
24032 |
-if test -z "${ENABLE_XML_TRUE}" && test -z "${ENABLE_XML_FALSE}"; then |
|
24033 |
- as_fn_error $? "conditional \"ENABLE_XML\" was never defined. |
|
24034 |
-Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
|
24035 |
-fi |
|
24036 | 24032 |
if test -z "${BUILD_CLAMD_TRUE}" && test -z "${BUILD_CLAMD_FALSE}"; then |
24037 | 24033 |
as_fn_error $? "conditional \"BUILD_CLAMD\" was never defined. |
24038 | 24034 |
Usually this means the macro was only invoked conditionally." "$LINENO" 5 |
... | ... |
@@ -653,24 +653,92 @@ AC_ARG_ENABLE([unrar], |
653 | 653 |
want_unrar=$enableval, want_unrar="yes") |
654 | 654 |
AM_CONDITIONAL([ENABLE_UNRAR],[test "$want_unrar" = "yes"]) |
655 | 655 |
|
656 |
-want_xml="yes" |
|
656 |
+want_xml="auto" |
|
657 | 657 |
AC_ARG_ENABLE([xml], |
658 | 658 |
[ --disable-xml disable DMG and XAR support], |
659 |
-want_xml=$enableval, want_xml="yes") |
|
660 |
-AM_CONDITIONAL([ENABLE_XML],[test "$want_xml" = "yes"]) |
|
659 |
+want_xml=$enableval, want_xml="auto") |
|
661 | 660 |
|
662 |
-if test "$want_xml" = "yes" |
|
663 |
-then |
|
664 |
- AM_PATH_XML2(2.5.0) |
|
665 |
- AC_DEFINE([HAVE_LIBXML2],1,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
661 |
+working_xml="no" |
|
662 |
+if test "$want_xml" != "no"; then |
|
663 |
+ AC_MSG_CHECKING([for libxml2 installation]) |
|
664 |
+ AC_ARG_WITH([xml], |
|
665 |
+ [ --with-xml=DIR path to directory containing libxml2 library (default= |
|
666 |
+ /usr/local or /usr if not found in /usr/local)], |
|
667 |
+ [ |
|
668 |
+ if test "$withval" |
|
669 |
+ then |
|
670 |
+ XML_HOME="$withval" |
|
671 |
+ AC_MSG_RESULT([using $XML_HOME]) |
|
672 |
+ fi |
|
673 |
+ ], [ |
|
674 |
+ XML_HOME=/usr/local |
|
675 |
+ if test ! -f "$XML_HOME/include/libxml/xmlreader.h" |
|
676 |
+ then |
|
677 |
+ XML_HOME=/usr |
|
678 |
+ fi |
|
679 |
+ AC_MSG_RESULT([$XML_HOME]) |
|
680 |
+ ]) |
|
681 |
+ |
|
682 |
+ AC_MSG_WARN([****** checking XML_HOME $XML_HOME ******]) |
|
683 |
+ |
|
684 |
+ if test ! -f "$XML_HOME/include/libxml2/libxml/xmlreader.h"; then |
|
685 |
+ AC_MSG_WARN([****** not found, cannot test ******]) |
|
686 |
+ if test "$want_xml" = "yes"; then |
|
687 |
+ AC_MSG_ERROR([Please install libxml2 packages]) |
|
688 |
+ fi |
|
689 |
+ else |
|
690 |
+ AC_MSG_WARN([****** found, testing ******]) |
|
691 |
+ save_LIBS="$LIBS" |
|
692 |
+ if test "$XML_HOME" != "/usr"; then |
|
693 |
+ save_CPPFLAGS="$CPPFLAGS" |
|
694 |
+ CPPFLAGS="$CPPFLAGS -I$XML_HOME/include" |
|
695 |
+ save_LDFLAGS="$LDFLAGS" |
|
696 |
+ LDFLAGS="$LDFLAGS -Wl,-rpath $XML_HOME/lib" |
|
697 |
+ AC_CHECK_LIB([xml2], [xmlTextReaderRead], [working_xml="yes";XML_CPPFLAGS="-I/usr/include/libxml2";XML_LIBS="-Wl,-rpath $XML_HOME/lib -lxml2"], working_xml="no") |
|
698 |
+ CPPFLAGS="$save_CPPFLAGS" |
|
699 |
+ LDFLAGS="$save_LDFLAGS" |
|
700 |
+ else |
|
701 |
+ AC_CHECK_LIB([xml2], [xmlTextReaderRead], [working_xml="yes";XML_CPPFLAGS="-I/usr/include/libxml2";XML_LIBS="-lxml2"], working_xml="no") |
|
702 |
+ fi |
|
703 |
+ LIBS="$save_LIBS" |
|
704 |
+ fi |
|
705 |
+fi |
|
706 |
+ |
|
707 |
+if test "$working_xml" = "yes"; then |
|
708 |
+ AC_DEFINE([HAVE_LIBXML2],1,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
709 |
+ AC_DEFINE([ENABLE_XML],1,[Define to 1 if xml supported features can be enabled.]) |
|
710 |
+ AC_SUBST(XML_CPPFLAGS) |
|
711 |
+ AC_SUBST(XML_LIBS) |
|
666 | 712 |
else |
667 |
- XML_CPPFLAGS="" |
|
668 |
- XML_LIBS="" |
|
669 |
- AC_SUBST(XML_CPPFLAGS) |
|
670 |
- AC_SUBST(XML_LIBS) |
|
671 |
- AC_DEFINE([HAVE_LIBXML2],0,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
713 |
+ if test "$want_xml" = "yes"; then |
|
714 |
+ AC_MSG_ERROR([Please install libxml2 packages]) |
|
715 |
+ fi |
|
716 |
+ XML_CPPFLAGS="" |
|
717 |
+ XML_LIBS="" |
|
718 |
+ AC_SUBST(XML_CPPFLAGS) |
|
719 |
+ AC_SUBST(XML_LIBS) |
|
720 |
+ AC_DEFINE([HAVE_LIBXML2],0,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
721 |
+ AC_DEFINE([ENABLE_XML],0,[Define to 1 if xml supported features can be enabled.]) |
|
672 | 722 |
fi |
673 | 723 |
|
724 |
+dnl want_xml="yes" |
|
725 |
+dnl AC_ARG_ENABLE([xml], |
|
726 |
+dnl [ --disable-xml disable DMG and XAR support], |
|
727 |
+dnl want_xml=$enableval, want_xml="yes") |
|
728 |
+dnl AM_CONDITIONAL([ENABLE_XML],[test "$want_xml" = "yes"]) |
|
729 |
+ |
|
730 |
+dnl if test "$want_xml" = "yes" |
|
731 |
+dnl then |
|
732 |
+ dnl AM_PATH_XML2(2.5.0) |
|
733 |
+ dnl AC_DEFINE([HAVE_LIBXML2],1,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
734 |
+dnl else |
|
735 |
+ dnl XML_CPPFLAGS="" |
|
736 |
+ dnl XML_LIBS="" |
|
737 |
+ dnl AC_SUBST(XML_CPPFLAGS) |
|
738 |
+ dnl AC_SUBST(XML_LIBS) |
|
739 |
+ dnl AC_DEFINE([HAVE_LIBXML2],0,[Define to 1 if you have the 'libxml2' library (-lxml2).]) |
|
740 |
+dnl fi |
|
741 |
+ |
|
674 | 742 |
AC_ARG_ENABLE([getaddrinfo], |
675 | 743 |
[ --disable-getaddrinfo disable support for getaddrinfo], |
676 | 744 |
want_getaddrinfo=$enableval, want_getaddrinfo="yes") |
... | ... |
@@ -209,7 +209,6 @@ VERSION = @VERSION@ |
209 | 209 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
210 | 210 |
WERR_CFLAGS = @WERR_CFLAGS@ |
211 | 211 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
212 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
213 | 212 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
214 | 213 |
XML_LIBS = @XML_LIBS@ |
215 | 214 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -242,7 +242,6 @@ VERSION = @VERSION@ |
242 | 242 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
243 | 243 |
WERR_CFLAGS = @WERR_CFLAGS@ |
244 | 244 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
245 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
246 | 245 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
247 | 246 |
XML_LIBS = @XML_LIBS@ |
248 | 247 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -239,7 +239,6 @@ VERSION = @VERSION@ |
239 | 239 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
240 | 240 |
WERR_CFLAGS = @WERR_CFLAGS@ |
241 | 241 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
242 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
243 | 242 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
244 | 243 |
XML_LIBS = @XML_LIBS@ |
245 | 244 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -245,7 +245,6 @@ VERSION = @VERSION@ |
245 | 245 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
246 | 246 |
WERR_CFLAGS = @WERR_CFLAGS@ |
247 | 247 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
248 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
249 | 248 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
250 | 249 |
XML_LIBS = @XML_LIBS@ |
251 | 250 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -508,7 +508,6 @@ VERSION = @VERSION@ |
508 | 508 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
509 | 509 |
WERR_CFLAGS = @WERR_CFLAGS@ |
510 | 510 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
511 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
512 | 511 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
513 | 512 |
XML_LIBS = @XML_LIBS@ |
514 | 513 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -321,7 +321,6 @@ VERSION = @VERSION@ |
321 | 321 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
322 | 322 |
WERR_CFLAGS = @WERR_CFLAGS@ |
323 | 323 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
324 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
325 | 324 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
326 | 325 |
XML_LIBS = @XML_LIBS@ |
327 | 326 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -242,7 +242,6 @@ VERSION = @VERSION@ |
242 | 242 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
243 | 243 |
WERR_CFLAGS = @WERR_CFLAGS@ |
244 | 244 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
245 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
246 | 245 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
247 | 246 |
XML_LIBS = @XML_LIBS@ |
248 | 247 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -190,7 +190,6 @@ VERSION = @VERSION@ |
190 | 190 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
191 | 191 |
WERR_CFLAGS = @WERR_CFLAGS@ |
192 | 192 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
193 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
194 | 193 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
195 | 194 |
XML_LIBS = @XML_LIBS@ |
196 | 195 |
abs_builddir = @abs_builddir@ |
... | ... |
@@ -375,7 +375,6 @@ VERSION = @VERSION@ |
375 | 375 |
VERSIONSCRIPTFLAG = @VERSIONSCRIPTFLAG@ |
376 | 376 |
WERR_CFLAGS = @WERR_CFLAGS@ |
377 | 377 |
WERR_CFLAGS_MILTER = @WERR_CFLAGS_MILTER@ |
378 |
-XML2_CONFIG = @XML2_CONFIG@ |
|
379 | 378 |
XML_CPPFLAGS = @XML_CPPFLAGS@ |
380 | 379 |
XML_LIBS = @XML_LIBS@ |
381 | 380 |
abs_builddir = @abs_builddir@ |