blob: b16e280ba563f0cb09b59e43353316352e0ab980 [file] [log] [blame]
Daniel Veillard01791d51998-07-24 19:24:09 +00001dnl Process this file with autoconf to produce a configure script.
2AC_PREREQ(2.2)
Owen Taylor3473f882001-02-23 17:55:21 +00003AC_INIT(entities.c)
Daniel Veillard01791d51998-07-24 19:24:09 +00004AM_CONFIG_HEADER(config.h)
Daniel Veillardd2ade932000-09-30 14:39:55 +00005AC_CANONICAL_HOST
Daniel Veillard14fff061999-06-22 21:49:07 +00006
Daniel Veillardcf461992000-03-14 18:30:20 +00007LIBXML_MAJOR_VERSION=2
Daniel Veillard6a2e4062001-02-08 10:31:33 +00008LIBXML_MINOR_VERSION=3
Daniel Veillardb3a182e2001-06-01 09:28:09 +00009LIBXML_MICRO_VERSION=10
Daniel Veillard14fff061999-06-22 21:49:07 +000010LIBXML_VERSION=$LIBXML_MAJOR_VERSION.$LIBXML_MINOR_VERSION.$LIBXML_MICRO_VERSION
11LIBXML_VERSION_INFO=`expr $LIBXML_MAJOR_VERSION + $LIBXML_MINOR_VERSION`:$LIBXML_MICRO_VERSION:$LIBXML_MINOR_VERSION
12
Daniel Veillard361d8452000-04-03 19:48:13 +000013LIBXML_VERSION_NUMBER=`expr $LIBXML_MAJOR_VERSION \* 10000 + $LIBXML_MINOR_VERSION \* 100 + $LIBXML_MICRO_VERSION`
14
Daniel Veillard14fff061999-06-22 21:49:07 +000015AC_SUBST(LIBXML_MAJOR_VERSION)
16AC_SUBST(LIBXML_MINOR_VERSION)
17AC_SUBST(LIBXML_MICRO_VERSION)
18AC_SUBST(LIBXML_VERSION)
19AC_SUBST(LIBXML_VERSION_INFO)
Daniel Veillard361d8452000-04-03 19:48:13 +000020AC_SUBST(LIBXML_VERSION_NUMBER)
Daniel Veillard14fff061999-06-22 21:49:07 +000021
Daniel Veillard361d8452000-04-03 19:48:13 +000022VERSION=${LIBXML_VERSION}
Daniel Veillard14fff061999-06-22 21:49:07 +000023
Daniel Veillardedfb29b2000-03-14 19:59:05 +000024AM_INIT_AUTOMAKE(libxml2, $VERSION)
Daniel Veillard1164e751999-02-16 16:29:17 +000025
26AC_ARG_WITH(html-dir, [ --with-html-dir=PATH path to installed docs ])
Daniel Veillard01791d51998-07-24 19:24:09 +000027
28dnl Checks for programs.
29AC_PROG_CC
30AC_PROG_INSTALL
Sebastian Wilhelmia44c8a41998-08-07 08:38:58 +000031AC_PROG_CPP
Daniel Veillard01791d51998-07-24 19:24:09 +000032AC_PATH_PROG(RM, rm, /bin/rm)
33AC_PATH_PROG(MV, mv, /bin/mv)
34AC_PATH_PROG(TAR, tar, /bin/tar)
Daniel Veillard01791d51998-07-24 19:24:09 +000035
Daniel Veillard03109292000-08-14 14:58:22 +000036dnl Make sure we have an ANSI compiler
37AM_C_PROTOTYPES
38test "x$U" != "x" && AC_MSG_ERROR(Compiler not ANSI compliant)
39
Daniel Veillard01791d51998-07-24 19:24:09 +000040AM_PROG_LIBTOOL
41
42AM_MAINTAINER_MODE
43
Daniel Veillard71b656e2000-01-05 14:46:17 +000044dnl Checks for zlib library.
Owen Taylor3473f882001-02-23 17:55:21 +000045_cppflags="${CPPFLAGS}"
46_ldflags="${LDFLAGS}"
Daniel Veillard71b656e2000-01-05 14:46:17 +000047
Owen Taylor3473f882001-02-23 17:55:21 +000048AC_ARG_WITH(zlib,
49[ --with-zlib[=DIR] use libz in DIR],[
50 if test "$withval" != "no" -a "$withval" != "yes"; then
51 Z_DIR=$withval
52 CPPFLAGS="${CPPFLAGS} -I$withval/include"
53 LDFLAGS="${LDFLAGS} -L$withval/lib"
54 fi
55])
56
57AC_CHECK_HEADERS(zlib.h,
58 AC_CHECK_LIB(z, gzread,[
59 AC_DEFINE(HAVE_LIBZ)
60 if test "x${Z_DIR}" != "x"; then
61 Z_CFLAGS="-I${Z_DIR}/include"
62 Z_LIBS="-L${Z_DIR}/lib -lz"
Daniel Veillardc3739e72001-05-15 15:23:27 +000063 [case ${host} in
Daniel Veillarda4f27e02001-05-15 12:41:29 +000064 *-*-solaris*)
Daniel Veillardc3739e72001-05-15 15:23:27 +000065 Z_LIBS="-L${Z_DIR}/lib -R${Z_DIR}/lib -lz"
Daniel Veillarda4f27e02001-05-15 12:41:29 +000066 ;;
Daniel Veillardc3739e72001-05-15 15:23:27 +000067 esac]
Owen Taylor3473f882001-02-23 17:55:21 +000068 else
69 Z_LIBS="-lz"
70 fi]))
71AC_SUBST(Z_CFLAGS)
72AC_SUBST(Z_LIBS)
73
74CPPFLAGS=${_cppflags}
75LDFLAGS=${_ldflags}
Daniel Veillardb05deb71999-08-10 19:04:08 +000076
Daniel Veillard01791d51998-07-24 19:24:09 +000077dnl Checks for header files.
78AC_HEADER_DIRENT
79AC_HEADER_STDC
80AC_CHECK_HEADERS(fcntl.h unistd.h ctype.h dirent.h errno.h malloc.h)
Daniel Veillard27b55282001-04-11 12:22:25 +000081AC_CHECK_HEADERS(stdarg.h sys/stat.h sys/types.h time.h ansidecl.h)
Daniel Veillardb05deb71999-08-10 19:04:08 +000082AC_CHECK_HEADERS(ieeefp.h nan.h math.h fp_class.h float.h)
Daniel Veillard7f7d1111999-09-22 09:46:25 +000083AC_CHECK_HEADERS(stdlib.h sys/socket.h netinet/in.h arpa/inet.h)
Daniel Veillard46e370e2000-07-21 20:32:03 +000084AC_CHECK_HEADERS(netdb.h sys/time.h sys/select.h sys/mman.h)
Daniel Veillard068a9652001-06-07 15:30:26 +000085AC_CHECK_HEADERS(signal.h)
Daniel Veillard01791d51998-07-24 19:24:09 +000086
Daniel Veillard1164e751999-02-16 16:29:17 +000087dnl Specific dir for HTML output ?
88if test "x$with_html_dir" = "x" ; then
Daniel Veillard0a6c3582001-03-14 19:15:37 +000089 HTML_DIR='$(prefix)/doc'
Daniel Veillard1164e751999-02-16 16:29:17 +000090else
91 HTML_DIR=$with_html_dir
92fi
93
94AC_SUBST(HTML_DIR)
95
Daniel Veillardb0426ca2000-10-11 23:39:43 +000096AC_ARG_ENABLE(corba,
97[ --enable-corba Add Corba support (default)])
Daniel Veillard27fb0751998-10-17 06:47:46 +000098
99dnl
100dnl Corba is enabled by default
101dnl
Daniel Veillardda4d3c41998-11-04 20:07:05 +0000102if test "$enable_corba" = "no" ; then
Daniel Veillard27fb0751998-10-17 06:47:46 +0000103 CORBA_CFLAGS="-DWITHOUT_CORBA"
104fi
105AC_SUBST(CORBA_CFLAGS)
106
Daniel Veillard01791d51998-07-24 19:24:09 +0000107dnl Checks for library functions.
108AC_FUNC_STRFTIME
Daniel Veillard92ad2102001-03-27 12:47:33 +0000109AC_CHECK_FUNCS(strdup strndup strerror)
Daniel Veillard71b656e2000-01-05 14:46:17 +0000110AC_CHECK_FUNCS(finite isnand fp_class class fpclass)
Daniel Veillard7f7d1111999-09-22 09:46:25 +0000111AC_CHECK_FUNCS(strftime localtime)
Daniel Veillard068a9652001-06-07 15:30:26 +0000112AC_CHECK_FUNCS(stat _stat signal)
Daniel Veillard7f7d1111999-09-22 09:46:25 +0000113
Daniel Veillard92ad2102001-03-27 12:47:33 +0000114dnl Checking the standard string functions availability
115AC_CHECK_FUNCS(printf sprintf fprintf snprintf vfprintf vsprintf vsnprintf sscanf,,
116 NEED_TRIO=1)
117
Daniel Veillard7f7d1111999-09-22 09:46:25 +0000118dnl Checks for inet libraries:
Daniel Veillard71b656e2000-01-05 14:46:17 +0000119AC_CHECK_FUNC(gethostent, , AC_CHECK_LIB(nsl, gethostent))
120AC_CHECK_FUNC(setsockopt, , AC_CHECK_LIB(socket, setsockopt))
121AC_CHECK_FUNC(connect, , AC_CHECK_LIB(inet, connect))
Daniel Veillardb05deb71999-08-10 19:04:08 +0000122
Daniel Veillardb0426ca2000-10-11 23:39:43 +0000123dnl Determine what socket length (socklen_t) data type is
124AC_MSG_CHECKING([for type of socket length (socklen_t)])
125AC_TRY_COMPILE2([
126#include <stddef.h>
127#include <sys/types.h>
128#include <sys/socket.h>],[
129(void)getsockopt (1, 1, 1, NULL, (socklen_t *)NULL)],[
130 AC_MSG_RESULT(socklen_t *)
131 SOCKLEN_T=socklen_t],[
132 AC_TRY_COMPILE2([
133#include <stddef.h>
134#include <sys/types.h>
135#include <sys/socket.h>],[
136(void)getsockopt (1, 1, 1, NULL, (size_t *)NULL)],[
137 AC_MSG_RESULT(size_t *)
138 SOCKLEN_T=size_t],[
139 AC_TRY_COMPILE2([
140#include <stddef.h>
141#include <sys/types.h>
142#include <sys/socket.h>],[
143(void)getsockopt (1, 1, 1, NULL, (int *)NULL)],[
144 AC_MSG_RESULT(int *)
145 SOCKLEN_T=int],[
146 AC_MSG_WARN(could not determine)])])])
147AC_DEFINE_UNQUOTED(SOCKLEN_T, $SOCKLEN_T)
148
Daniel Veillardb05deb71999-08-10 19:04:08 +0000149dnl Checks for isnan in libm if not in libc
Daniel Veillard71b656e2000-01-05 14:46:17 +0000150AC_CHECK_FUNC(isnan, , AC_CHECK_LIB(m, isnan,
Bjorn Reesee1dc0112001-03-03 12:09:03 +0000151 [AC_DEFINE(HAVE_ISNAN)]))
Daniel Veillardb05deb71999-08-10 19:04:08 +0000152
Daniel Veillard760f4422001-02-15 14:59:48 +0000153AC_CHECK_FUNC(isinf, AC_DEFINE(HAVE_ISINF) , AC_CHECK_LIB(m, isinf,
Bjorn Reesee1dc0112001-03-03 12:09:03 +0000154 [AC_DEFINE(HAVE_ISINF)]))
Daniel Veillardb05deb71999-08-10 19:04:08 +0000155
156XML_LIBDIR='-L${libdir}'
Daniel Veillarde8282ed2000-10-10 23:01:31 +0000157XML_INCLUDEDIR='-I${includedir}/libxml -I${includedir}'
Daniel Veillardb05deb71999-08-10 19:04:08 +0000158
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000159dnl
Daniel Veillardf5c2c871999-12-01 09:51:45 +0000160dnl Extra flags
161dnl
162XML_CFLAGS=""
Daniel Veillard357c9602001-05-03 10:49:20 +0000163RDL_LIBS=""
Daniel Veillardf5c2c871999-12-01 09:51:45 +0000164
165dnl
Daniel Veillardb45c43b2001-04-28 17:02:11 +0000166dnl Workaround for native compilers
167dnl HP : http://bugs.gnome.org/db/31/3163.html
168dnl DEC : Enable NaN/Inf
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000169dnl
Daniel Veillard03109292000-08-14 14:58:22 +0000170if test "${GCC}" != "yes" ; then
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000171 case "${host}" in
172 *-*-hpux* )
Daniel Veillard03109292000-08-14 14:58:22 +0000173 CFLAGS="${CFLAGS} -Wp,-H30000"
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000174 ;;
Daniel Veillardb45c43b2001-04-28 17:02:11 +0000175 *-dec-osf* )
176 CFLAGS="${CFLAGS} -ieee"
177 ;;
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000178 esac
Daniel Veillardd574f782001-03-14 19:40:17 +0000179else
180 CFLAGS="${CFLAGS} -Wall"
Daniel Veillard14839d52001-06-06 16:11:56 +0000181 case "${host}" in
182 alpha*-*-linux* )
183 CFLAGS="${CFLAGS} -mieee"
184 ;;
185 esac
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000186fi
Daniel Veillardb0426ca2000-10-11 23:39:43 +0000187case ${host} in
188 *-*-solaris*)
Daniel Veillardd2ade932000-09-30 14:39:55 +0000189 XML_LIBDIR="${XML_LIBDIR} -R${libdir}"
190 ;;
191esac
192
Daniel Veillardf5c2c871999-12-01 09:51:45 +0000193
Daniel Veillardb0426ca2000-10-11 23:39:43 +0000194
Daniel Veillardf5c2c871999-12-01 09:51:45 +0000195dnl
196dnl Use buffers for content
197dnl
198
199AC_ARG_WITH(buffers, [ --with-buffers Use buffers for node content])
200if test "$with_buffers" = "yes" ; then
201 CFLAGS="${CFLAGS} -DXML_USE_BUFFER_CONTENT"
202 XML_CFLAGS="${XML_CFLAGS} -DXML_USE_BUFFER_CONTENT"
203fi
204
Daniel Veillard437b87b2000-01-03 17:30:46 +0000205dnl
206dnl Tester makes use of readline if present
207dnl
Daniel Veillard03109292000-08-14 14:58:22 +0000208_cppflags="${CPPFLAGS}"
209_ldflags="${LDFLAGS}"
Daniel Veillard437b87b2000-01-03 17:30:46 +0000210
Daniel Veillard03109292000-08-14 14:58:22 +0000211AC_ARG_WITH(readline,
212[ --with-readline=DIR use readline in DIR],[
213 if test "$withval" != "no" -a "$withval" != "yes"; then
214 RDL_DIR=$withval
215 CPPFLAGS="${CPPFLAGS} -I$withval/include"
216 LDFLAGS="${LDFLAGS} -L$withval/lib"
217 fi
218])
219
220dnl check for terminal library. this is a very cool solution
221dnl from octave's configure.in
222unset tcap
223for termlib in ncurses curses termcap terminfo termlib; do
224 AC_CHECK_LIB(${termlib}, tputs, [tcap="-l$termlib"])
225 test -n "$tcap" && break
226done
227
228AC_CHECK_HEADER(readline/history.h,
229 AC_CHECK_LIB(history, append_history,[
230 RDL_LIBS="-lhistory"
231 AC_DEFINE(HAVE_LIBHISTORY)]))
232AC_CHECK_HEADER(readline/readline.h,
233 AC_CHECK_LIB(readline, readline,[
234 RDL_LIBS="-lreadline $RDL_LIBS $tcap"
235 AC_DEFINE(HAVE_LIBREADLINE)], , $tcap))
236if test -n "$RDL_DIR" -a -n "$RDL_LIBS"; then
237 CPPFLAGS="$CPPFLAGS -I${RDL_DIR}/include"
238 RDL_LIBS="-L${RDL_DIR}/lib $RDL_LIBS"
239else
240 CPPFLAGS=${_cppflags}
241fi
242LDFLAGS=${_ldflags}
243
Daniel Veillard361d8452000-04-03 19:48:13 +0000244dnl
Daniel Veillardf6eea272001-01-18 12:17:12 +0000245dnl specific tests to setup DV's devel environment with debug etc ...
Daniel Veillard81418e32001-05-22 15:08:55 +0000246dnl (-Wunreachable-code)
Daniel Veillardf6eea272001-01-18 12:17:12 +0000247dnl
248if test "${LOGNAME}" = "veillard" -a "`pwd`" = "/u/veillard/XML" ; then
249 if test "${with_mem_debug}" = "" ; then
250 with_mem_debug="yes"
251 fi
Daniel Veillardeae522a2001-04-23 13:41:34 +0000252 if test "${with_docbook}" = "" ; then
253 with_docbook="yes"
254 fi
Daniel Veillardf6eea272001-01-18 12:17:12 +0000255 if test "${with_xptr}" = "" ; then
256 with_xptr="yes"
257 fi
Daniel Veillard14839d52001-06-06 16:11:56 +0000258 CFLAGS="${CFLAGS} -g -O -pedantic -W -Wunused -Wimplicit -Wreturn-type -Wswitch -Wcomment -Wtrigraphs -Wformat -Wchar-subscripts -Wuninitialized -Wparentheses -Wshadow -Wpointer-arith -Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline "
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000259dnl -Wcast-qual -ansi
Daniel Veillardf6eea272001-01-18 12:17:12 +0000260fi
Daniel Veillard92ad2102001-03-27 12:47:33 +0000261
262dnl
263dnl Check for trio string functions
264dnl
265
266if test "${NEED_TRIO}" = "1" ; then
267 echo Adding trio library for string functions
268 WITH_TRIO=1
269else
270 WITH_TRIO=0
271fi
Daniel Veillard01ef7382001-05-08 07:31:43 +0000272AM_CONDITIONAL(WITH_TRIO_SOURCES, test "${NEED_TRIO}" = "1")
Daniel Veillard92ad2102001-03-27 12:47:33 +0000273AC_SUBST(WITH_TRIO)
274
Daniel Veillardf6eea272001-01-18 12:17:12 +0000275dnl
Daniel Veillard361d8452000-04-03 19:48:13 +0000276dnl Aloow to disable various pieces
277dnl
278
279AC_ARG_WITH(ftp, [ --with-ftp Add the FTP support (on)])
280if test "$with_ftp" = "no" ; then
281 echo Disabling FTP support
282 WITH_FTP=0
283 FTP_OBJ=
284else
285 WITH_FTP=1
286 FTP_OBJ=nanoftp.o
287fi
288AC_SUBST(WITH_FTP)
289AC_SUBST(FTP_OBJ)
290
291AC_ARG_WITH(http, [ --with-http Add the HTTP support (on)])
292if test "$with_http" = "no" ; then
293 echo Disabling HTTP support
294 WITH_HTTP=0
295 HTTP_OBJ=
296else
297 WITH_HTTP=1
298 HTTP_OBJ=nanohttp.o
299fi
300AC_SUBST(WITH_HTTP)
301AC_SUBST(HTTP_OBJ)
302
303AC_ARG_WITH(html, [ --with-html Add the HTML support (on)])
304if test "$with_html" = "no" ; then
305 echo Disabling HTML support
306 WITH_HTML=0
307 HTML_OBJ=
308else
309 WITH_HTML=1
310 HTML_OBJ="HTMLparser.o HTMLtree.o"
311fi
312AC_SUBST(WITH_HTML)
313AC_SUBST(HTML_OBJ)
314
Daniel Veillarda7374592001-05-10 14:17:55 +0000315AC_ARG_WITH(catalog, [ --with-catalog Add the Catalog support (on)])
316if test "$with_catalog" = "no" ; then
317 echo Disabling Catalog support
318 WITH_CATALOG=0
319 CATALOG_OBJ=
320else
321 WITH_CATALOG=1
322 CATALOG_OBJ="catalog.o"
323fi
324AC_SUBST(WITH_CATALOG)
325AC_SUBST(CATALOG_OBJ)
326
Daniel Veillardb59076b2001-04-29 17:04:07 +0000327AC_ARG_WITH(docbook, [ --with-docbook Add Docbook SGML support (on)])
328if test "$with_docbook" = "no" ; then
329 echo Disabling Docbook support
Daniel Veillardeae522a2001-04-23 13:41:34 +0000330 WITH_DOCB=0
331 DOCB_OBJ=
Daniel Veillardb59076b2001-04-29 17:04:07 +0000332else
333 WITH_DOCB=1
334 DOCB_OBJ="DOCBparser.o"
Daniel Veillardeae522a2001-04-23 13:41:34 +0000335fi
336AC_SUBST(WITH_DOCB)
337AC_SUBST(DOCB_OBJ)
338
339
Daniel Veillard361d8452000-04-03 19:48:13 +0000340AC_ARG_WITH(xpath, [ --with-xpath Add the XPATH support (on)])
341if test "$with_xpath" = "no" ; then
342 echo Disabling XPATH support
Daniel Veillard52afe802000-10-22 16:56:02 +0000343 with_xptr="no"
Daniel Veillard361d8452000-04-03 19:48:13 +0000344 WITH_XPATH=0
345 XPATH_OBJ=
346else
347 WITH_XPATH=1
348 XPATH_OBJ=xpath.o
349fi
350AC_SUBST(WITH_XPATH)
351AC_SUBST(XPATH_OBJ)
352
Daniel Veillardc8df0aa2000-10-10 23:50:30 +0000353AC_ARG_WITH(xptr, [ --with-xptr Add the XPointer support (on)])
354if test "$with_xptr" = "no" ; then
355 echo Disabling XPointer support
356 WITH_XPTR=0
357 XPTR_OBJ=
358else
359 WITH_XPTR=1
360 XPTR_OBJ=xpointer.o
361fi
362AC_SUBST(WITH_XPTR)
363AC_SUBST(XPTR_OBJ)
364
Daniel Veillard9e8bfae2000-11-06 16:43:11 +0000365AC_ARG_WITH(xinclude, [ --with-xinclude Add the XInclude support (on)])
366if test "$with_xinclude" = "no" ; then
367 echo Disabling XInclude support
368 WITH_XINCLUDE=0
369 XINCLUDE_OBJ=
370 with_xinclude="no"
371else
372 WITH_XINCLUDE=1
373 XINCLUDE_OBJ=xinclude.o
374fi
375AC_SUBST(WITH_XINCLUDE)
376AC_SUBST(XINCLUDE_OBJ)
377
Daniel Veillard496a1cf2000-05-03 14:20:55 +0000378AC_ARG_WITH(iconv, [ --with-iconv Add the ICONV support (on)])
379if test "$with_iconv" = "no" ; then
380 echo Disabling ICONV support
381 WITH_ICONV=0
Daniel Veillardd574f782001-03-14 19:40:17 +0000382else
383 AC_CHECK_HEADER(iconv.h,
Daniel Veillarda2bc3682001-05-03 08:27:20 +0000384 AC_CHECK_FUNC(iconv, ,
Daniel Veillard81418e32001-05-22 15:08:55 +0000385 AC_CHECK_LIB(iconv, iconv, ICONV_LIBS="-liconv")))
Daniel Veillard496a1cf2000-05-03 14:20:55 +0000386 if test "$have_iconv" != "" ; then
387 echo Iconv support not found
388 WITH_ICONV=0
389 else
390 WITH_ICONV=1
391 fi
392fi
Daniel Veillard81418e32001-05-22 15:08:55 +0000393XML_LIBS="-lxml2 $Z_LIBS $ICONV_LIBS -lm $LIBS"
Daniel Veillard496a1cf2000-05-03 14:20:55 +0000394AC_SUBST(WITH_ICONV)
395
Daniel Veillard361d8452000-04-03 19:48:13 +0000396AC_ARG_WITH(debug, [ --with-debug Add the debugging module (on)])
397if test "$with_debug" = "no" ; then
398 echo Disabling DEBUG support
399 WITH_DEBUG=0
400 DEBUG_OBJ=
401else
402 WITH_DEBUG=1
403 DEBUG_OBJ=debugXML.o
404fi
405AC_SUBST(WITH_DEBUG)
406AC_SUBST(DEBUG_OBJ)
407
408AC_ARG_WITH(mem_debug, [ --with-mem-debug Add the memory debugging module (off)])
409if test "$with_mem_debug" = "yes" ; then
410 echo Enabling memory debug support
411 WITH_MEM_DEBUG=1
412else
413 WITH_MEM_DEBUG=0
414fi
415AC_SUBST(WITH_MEM_DEBUG)
416
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000417AC_SUBST(CFLAGS)
Daniel Veillardf5c2c871999-12-01 09:51:45 +0000418AC_SUBST(XML_CFLAGS)
Daniel Veillardd7e200c1999-11-15 17:53:11 +0000419
Daniel Veillardb05deb71999-08-10 19:04:08 +0000420AC_SUBST(XML_LIBDIR)
421AC_SUBST(XML_LIBS)
Daniel Veillard81418e32001-05-22 15:08:55 +0000422AC_SUBST(ICONV_LIBS)
Daniel Veillardb05deb71999-08-10 19:04:08 +0000423AC_SUBST(XML_INCLUDEDIR)
424AC_SUBST(HTML_DIR)
425AC_SUBST(HAVE_ISNAN)
426AC_SUBST(HAVE_ISINF)
427
Daniel Veillardb05deb71999-08-10 19:04:08 +0000428AC_SUBST(M_LIBS)
Daniel Veillard437b87b2000-01-03 17:30:46 +0000429AC_SUBST(RDL_LIBS)
Daniel Veillard361d8452000-04-03 19:48:13 +0000430
Owen Taylor3473f882001-02-23 17:55:21 +0000431dnl
432dnl create the libxml and include links needed to get dependencies right
433dnl
434if test ! -d $srcdir/include/libxml
435then
436 if test ! -d $srcdir/include
437 then
438 rm -f $srcdir/include
439 mkdir $srcdir/include
440 fi
441 rm -f $srcdir/libxml
442 (cd $srcdir/include ; ln -s .. libxml)
443fi
444if test ! -r $srcdir/libxml
445then
446 (cd $srcdir ; ln -s include/libxml libxml)
447fi
448if test ! -r include/libxml
449then
450 if test ! -d include
451 then
452 rm -f include
453 mkdir include
454 fi
455 (cd include ; ln -s ../libxml libxml)
456fi
457if test ! -r libxml
458then
459 rm -rf libxml
460 ln -s $srcdir/include/libxml libxml
461fi
462
463AC_OUTPUT(libxml.spec Makefile include/Makefile doc/Makefile example/Makefile libxml/xmlversion.h xml2-config libxml-2.0.pc xml2Conf.sh)
Arturo Espinosa15fe6e71998-09-07 17:27:57 +0000464