]> git.lyx.org Git - lyx.git/blob - boost/aclocal.m4
mathed13.diff
[lyx.git] / boost / aclocal.m4
1 dnl aclocal.m4 generated automatically by aclocal 1.4
2
3 dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
4 dnl This file is free software; the Free Software Foundation
5 dnl gives unlimited permission to copy and/or distribute it,
6 dnl with or without modifications, as long as this notice is preserved.
7
8 dnl This program is distributed in the hope that it will be useful,
9 dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
10 dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
11 dnl PARTICULAR PURPOSE.
12
13
14 dnl AC_VALIDATE_CACHE_SYSTEM_TYPE[(cmd)]
15 dnl if the cache file is inconsistent with the current host,
16 dnl target and build system types, execute CMD or print a default
17 dnl error message.
18 AC_DEFUN(AC_VALIDATE_CACHE_SYSTEM_TYPE, [
19     AC_REQUIRE([AC_CANONICAL_SYSTEM])
20     AC_MSG_CHECKING([config.cache system type])
21     if { test x"${ac_cv_host_system_type+set}" = x"set" &&
22          test x"$ac_cv_host_system_type" != x"$host"; } ||
23        { test x"${ac_cv_build_system_type+set}" = x"set" &&
24          test x"$ac_cv_build_system_type" != x"$build"; } ||
25        { test x"${ac_cv_target_system_type+set}" = x"set" &&
26          test x"$ac_cv_target_system_type" != x"$target"; }; then
27         AC_MSG_RESULT([different])
28         ifelse($#, 1, [$1],
29                 [AC_MSG_ERROR(["you must remove config.cache and restart configure"])])
30     else
31         AC_MSG_RESULT([same])
32     fi
33     ac_cv_host_system_type="$host"
34     ac_cv_build_system_type="$build"
35     ac_cv_target_system_type="$target"
36 ])
37
38
39 # Like AC_CONFIG_HEADER, but automatically create stamp file.
40
41 AC_DEFUN(AM_CONFIG_HEADER,
42 [AC_PREREQ([2.12])
43 AC_CONFIG_HEADER([$1])
44 dnl When config.status generates a header, we must update the stamp-h file.
45 dnl This file resides in the same directory as the config header
46 dnl that is generated.  We must strip everything past the first ":",
47 dnl and everything past the last "/".
48 AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
49 ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
50 <<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
51 <<am_indx=1
52 for am_file in <<$1>>; do
53   case " <<$>>CONFIG_HEADERS " in
54   *" <<$>>am_file "*<<)>>
55     echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
56     ;;
57   esac
58   am_indx=`expr "<<$>>am_indx" + 1`
59 done<<>>dnl>>)
60 changequote([,]))])
61
62 # Do all the work for Automake.  This macro actually does too much --
63 # some checks are only needed if your package does certain things.
64 # But this isn't really a big deal.
65
66 # serial 1
67
68 dnl Usage:
69 dnl AM_INIT_AUTOMAKE(package,version, [no-define])
70
71 AC_DEFUN(AM_INIT_AUTOMAKE,
72 [AC_REQUIRE([AC_PROG_INSTALL])
73 PACKAGE=[$1]
74 AC_SUBST(PACKAGE)
75 VERSION=[$2]
76 AC_SUBST(VERSION)
77 dnl test to see if srcdir already configured
78 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
79   AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
80 fi
81 ifelse([$3],,
82 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
83 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
84 AC_REQUIRE([AM_SANITY_CHECK])
85 AC_REQUIRE([AC_ARG_PROGRAM])
86 dnl FIXME This is truly gross.
87 missing_dir=`cd $ac_aux_dir && pwd`
88 AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
89 AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
90 AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
91 AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
92 AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
93 AC_REQUIRE([AC_PROG_MAKE_SET])])
94
95 #
96 # Check to make sure that the build environment is sane.
97 #
98
99 AC_DEFUN(AM_SANITY_CHECK,
100 [AC_MSG_CHECKING([whether build environment is sane])
101 # Just in case
102 sleep 1
103 echo timestamp > conftestfile
104 # Do `set' in a subshell so we don't clobber the current shell's
105 # arguments.  Must try -L first in case configure is actually a
106 # symlink; some systems play weird games with the mod time of symlinks
107 # (eg FreeBSD returns the mod time of the symlink's containing
108 # directory).
109 if (
110    set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
111    if test "[$]*" = "X"; then
112       # -L didn't work.
113       set X `ls -t $srcdir/configure conftestfile`
114    fi
115    if test "[$]*" != "X $srcdir/configure conftestfile" \
116       && test "[$]*" != "X conftestfile $srcdir/configure"; then
117
118       # If neither matched, then we have a broken ls.  This can happen
119       # if, for instance, CONFIG_SHELL is bash and it inherits a
120       # broken ls alias from the environment.  This has actually
121       # happened.  Such a system could not be considered "sane".
122       AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
123 alias in your environment])
124    fi
125
126    test "[$]2" = conftestfile
127    )
128 then
129    # Ok.
130    :
131 else
132    AC_MSG_ERROR([newly created file is older than distributed files!
133 Check your system clock])
134 fi
135 rm -f conftest*
136 AC_MSG_RESULT(yes)])
137
138 dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
139 dnl The program must properly implement --version.
140 AC_DEFUN(AM_MISSING_PROG,
141 [AC_MSG_CHECKING(for working $2)
142 # Run test in a subshell; some versions of sh will print an error if
143 # an executable is not found, even if stderr is redirected.
144 # Redirect stdin to placate older versions of autoconf.  Sigh.
145 if ($2 --version) < /dev/null > /dev/null 2>&1; then
146    $1=$2
147    AC_MSG_RESULT(found)
148 else
149    $1="$3/missing $2"
150    AC_MSG_RESULT(missing)
151 fi
152 AC_SUBST($1)])
153
154
155 # serial 40 AC_PROG_LIBTOOL
156 AC_DEFUN(AC_PROG_LIBTOOL,
157 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
158
159 # Save cache, so that ltconfig can load it
160 AC_CACHE_SAVE
161
162 # Actually configure libtool.  ac_aux_dir is where install-sh is found.
163 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
164 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
165 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
166 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
167 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
168 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
169 || AC_MSG_ERROR([libtool configure failed])
170
171 # Reload cache, that may have been modified by ltconfig
172 AC_CACHE_LOAD
173
174 # This can be used to rebuild libtool when needed
175 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
176
177 # Always use our own libtool.
178 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
179 AC_SUBST(LIBTOOL)dnl
180
181 # Redirect the config.log output again, so that the ltconfig log is not
182 # clobbered by the next message.
183 exec 5>>./config.log
184 ])
185
186 AC_DEFUN(AC_LIBTOOL_SETUP,
187 [AC_PREREQ(2.13)dnl
188 AC_REQUIRE([AC_ENABLE_SHARED])dnl
189 AC_REQUIRE([AC_ENABLE_STATIC])dnl
190 AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
191 AC_REQUIRE([AC_CANONICAL_HOST])dnl
192 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
193 AC_REQUIRE([AC_PROG_RANLIB])dnl
194 AC_REQUIRE([AC_PROG_CC])dnl
195 AC_REQUIRE([AC_PROG_LD])dnl
196 AC_REQUIRE([AC_PROG_NM])dnl
197 AC_REQUIRE([AC_PROG_LN_S])dnl
198 dnl
199
200 case "$target" in
201 NONE) lt_target="$host" ;;
202 *) lt_target="$target" ;;
203 esac
204
205 # Check for any special flags to pass to ltconfig.
206 #
207 # the following will cause an existing older ltconfig to fail, so
208 # we ignore this at the expense of the cache file... Checking this 
209 # will just take longer ... bummer!
210 #libtool_flags="--cache-file=$cache_file"
211 #
212 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
213 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
214 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
215 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
216 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
217 ifdef([AC_PROVIDE_AC_LIBTOOL_DLOPEN],
218 [libtool_flags="$libtool_flags --enable-dlopen"])
219 ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
220 [libtool_flags="$libtool_flags --enable-win32-dll"])
221 AC_ARG_ENABLE(libtool-lock,
222   [  --disable-libtool-lock  avoid locking (might break parallel builds)])
223 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
224 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
225
226 # Some flags need to be propagated to the compiler or linker for good
227 # libtool support.
228 case "$lt_target" in
229 *-*-irix6*)
230   # Find out which ABI we are using.
231   echo '[#]line __oline__ "configure"' > conftest.$ac_ext
232   if AC_TRY_EVAL(ac_compile); then
233     case "`/usr/bin/file conftest.o`" in
234     *32-bit*)
235       LD="${LD-ld} -32"
236       ;;
237     *N32*)
238       LD="${LD-ld} -n32"
239       ;;
240     *64-bit*)
241       LD="${LD-ld} -64"
242       ;;
243     esac
244   fi
245   rm -rf conftest*
246   ;;
247
248 *-*-sco3.2v5*)
249   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
250   SAVE_CFLAGS="$CFLAGS"
251   CFLAGS="$CFLAGS -belf"
252   AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
253     [AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])])
254   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
255     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
256     CFLAGS="$SAVE_CFLAGS"
257   fi
258   ;;
259
260 ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
261 [*-*-cygwin* | *-*-mingw*)
262   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
263   AC_CHECK_TOOL(AS, as, false)
264   AC_CHECK_TOOL(OBJDUMP, objdump, false)
265   ;;
266 ])
267 esac
268 ])
269
270 # AC_LIBTOOL_DLOPEN - enable checks for dlopen support
271 AC_DEFUN(AC_LIBTOOL_DLOPEN, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])])
272
273 # AC_LIBTOOL_WIN32_DLL - declare package support for building win32 dll's
274 AC_DEFUN(AC_LIBTOOL_WIN32_DLL, [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])])
275
276 # AC_ENABLE_SHARED - implement the --enable-shared flag
277 # Usage: AC_ENABLE_SHARED[(DEFAULT)]
278 #   Where DEFAULT is either `yes' or `no'.  If omitted, it defaults to
279 #   `yes'.
280 AC_DEFUN(AC_ENABLE_SHARED, [dnl
281 define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
282 AC_ARG_ENABLE(shared,
283 changequote(<<, >>)dnl
284 <<  --enable-shared[=PKGS]  build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
285 changequote([, ])dnl
286 [p=${PACKAGE-default}
287 case "$enableval" in
288 yes) enable_shared=yes ;;
289 no) enable_shared=no ;;
290 *)
291   enable_shared=no
292   # Look at the argument we got.  We use all the common list separators.
293   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
294   for pkg in $enableval; do
295     if test "X$pkg" = "X$p"; then
296       enable_shared=yes
297     fi
298   done
299   IFS="$ac_save_ifs"
300   ;;
301 esac],
302 enable_shared=AC_ENABLE_SHARED_DEFAULT)dnl
303 ])
304
305 # AC_DISABLE_SHARED - set the default shared flag to --disable-shared
306 AC_DEFUN(AC_DISABLE_SHARED, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
307 AC_ENABLE_SHARED(no)])
308
309 # AC_ENABLE_STATIC - implement the --enable-static flag
310 # Usage: AC_ENABLE_STATIC[(DEFAULT)]
311 #   Where DEFAULT is either `yes' or `no'.  If omitted, it defaults to
312 #   `yes'.
313 AC_DEFUN(AC_ENABLE_STATIC, [dnl
314 define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
315 AC_ARG_ENABLE(static,
316 changequote(<<, >>)dnl
317 <<  --enable-static[=PKGS]  build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
318 changequote([, ])dnl
319 [p=${PACKAGE-default}
320 case "$enableval" in
321 yes) enable_static=yes ;;
322 no) enable_static=no ;;
323 *)
324   enable_static=no
325   # Look at the argument we got.  We use all the common list separators.
326   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
327   for pkg in $enableval; do
328     if test "X$pkg" = "X$p"; then
329       enable_static=yes
330     fi
331   done
332   IFS="$ac_save_ifs"
333   ;;
334 esac],
335 enable_static=AC_ENABLE_STATIC_DEFAULT)dnl
336 ])
337
338 # AC_DISABLE_STATIC - set the default static flag to --disable-static
339 AC_DEFUN(AC_DISABLE_STATIC, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
340 AC_ENABLE_STATIC(no)])
341
342
343 # AC_ENABLE_FAST_INSTALL - implement the --enable-fast-install flag
344 # Usage: AC_ENABLE_FAST_INSTALL[(DEFAULT)]
345 #   Where DEFAULT is either `yes' or `no'.  If omitted, it defaults to
346 #   `yes'.
347 AC_DEFUN(AC_ENABLE_FAST_INSTALL, [dnl
348 define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
349 AC_ARG_ENABLE(fast-install,
350 changequote(<<, >>)dnl
351 <<  --enable-fast-install[=PKGS]  optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
352 changequote([, ])dnl
353 [p=${PACKAGE-default}
354 case "$enableval" in
355 yes) enable_fast_install=yes ;;
356 no) enable_fast_install=no ;;
357 *)
358   enable_fast_install=no
359   # Look at the argument we got.  We use all the common list separators.
360   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
361   for pkg in $enableval; do
362     if test "X$pkg" = "X$p"; then
363       enable_fast_install=yes
364     fi
365   done
366   IFS="$ac_save_ifs"
367   ;;
368 esac],
369 enable_fast_install=AC_ENABLE_FAST_INSTALL_DEFAULT)dnl
370 ])
371
372 # AC_ENABLE_FAST_INSTALL - set the default to --disable-fast-install
373 AC_DEFUN(AC_DISABLE_FAST_INSTALL, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
374 AC_ENABLE_FAST_INSTALL(no)])
375
376 # AC_PROG_LD - find the path to the GNU or non-GNU linker
377 AC_DEFUN(AC_PROG_LD,
378 [AC_ARG_WITH(gnu-ld,
379 [  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]],
380 test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
381 AC_REQUIRE([AC_PROG_CC])dnl
382 AC_REQUIRE([AC_CANONICAL_HOST])dnl
383 AC_REQUIRE([AC_CANONICAL_BUILD])dnl
384 ac_prog=ld
385 if test "$ac_cv_prog_gcc" = yes; then
386   # Check if gcc -print-prog-name=ld gives a path.
387   AC_MSG_CHECKING([for ld used by GCC])
388   ac_prog=`($CC -print-prog-name=ld) 2>&5`
389   case "$ac_prog" in
390     # Accept absolute paths.
391 changequote(,)dnl
392     [\\/]* | [A-Za-z]:[\\/]*)
393       re_direlt='/[^/][^/]*/\.\./'
394 changequote([,])dnl
395       # Canonicalize the path of ld
396       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
397       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
398         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
399       done
400       test -z "$LD" && LD="$ac_prog"
401       ;;
402   "")
403     # If it fails, then pretend we aren't using GCC.
404     ac_prog=ld
405     ;;
406   *)
407     # If it is relative, then search for the first ld in PATH.
408     with_gnu_ld=unknown
409     ;;
410   esac
411 elif test "$with_gnu_ld" = yes; then
412   AC_MSG_CHECKING([for GNU ld])
413 else
414   AC_MSG_CHECKING([for non-GNU ld])
415 fi
416 AC_CACHE_VAL(ac_cv_path_LD,
417 [if test -z "$LD"; then
418   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
419   for ac_dir in $PATH; do
420     test -z "$ac_dir" && ac_dir=.
421     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
422       ac_cv_path_LD="$ac_dir/$ac_prog"
423       # Check to see if the program is GNU ld.  I'd rather use --version,
424       # but apparently some GNU ld's only accept -v.
425       # Break only if it was the GNU/non-GNU ld that we prefer.
426       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
427         test "$with_gnu_ld" != no && break
428       else
429         test "$with_gnu_ld" != yes && break
430       fi
431     fi
432   done
433   IFS="$ac_save_ifs"
434 else
435   ac_cv_path_LD="$LD" # Let the user override the test with a path.
436 fi])
437 LD="$ac_cv_path_LD"
438 if test -n "$LD"; then
439   AC_MSG_RESULT($LD)
440 else
441   AC_MSG_RESULT(no)
442 fi
443 test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
444 AC_PROG_LD_GNU
445 ])
446
447 AC_DEFUN(AC_PROG_LD_GNU,
448 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], ac_cv_prog_gnu_ld,
449 [# I'd rather use --version here, but apparently some GNU ld's only accept -v.
450 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
451   ac_cv_prog_gnu_ld=yes
452 else
453   ac_cv_prog_gnu_ld=no
454 fi])
455 ])
456
457 # AC_PROG_NM - find the path to a BSD-compatible name lister
458 AC_DEFUN(AC_PROG_NM,
459 [AC_MSG_CHECKING([for BSD-compatible nm])
460 AC_CACHE_VAL(ac_cv_path_NM,
461 [if test -n "$NM"; then
462   # Let the user override the test.
463   ac_cv_path_NM="$NM"
464 else
465   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
466   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
467     test -z "$ac_dir" && ac_dir=.
468     if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
469       # Check to see if the nm accepts a BSD-compat flag.
470       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
471       #   nm: unknown option "B" ignored
472       if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
473         ac_cv_path_NM="$ac_dir/nm -B"
474         break
475       elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
476         ac_cv_path_NM="$ac_dir/nm -p"
477         break
478       else
479         ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
480         continue # so that we can try to find one that supports BSD flags
481       fi
482     fi
483   done
484   IFS="$ac_save_ifs"
485   test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
486 fi])
487 NM="$ac_cv_path_NM"
488 AC_MSG_RESULT([$NM])
489 ])
490
491 # AC_CHECK_LIBM - check for math library
492 AC_DEFUN(AC_CHECK_LIBM,
493 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
494 LIBM=
495 case "$lt_target" in
496 *-*-beos* | *-*-cygwin*)
497   # These system don't have libm
498   ;;
499 *-ncr-sysv4.3*)
500   AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
501   AC_CHECK_LIB(m, main, LIBM="$LIBM -lm")
502   ;;
503 *)
504   AC_CHECK_LIB(m, main, LIBM="-lm")
505   ;;
506 esac
507 ])
508
509 # AC_LIBLTDL_CONVENIENCE[(dir)] - sets LIBLTDL to the link flags for
510 # the libltdl convenience library and INCLTDL to the include flags for
511 # the libltdl header and adds --enable-ltdl-convenience to the
512 # configure arguments.  Note that LIBLTDL and INCLTDL are not
513 # AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called.  If DIR is not
514 # provided, it is assumed to be `libltdl'.  LIBLTDL will be prefixed
515 # with '${top_builddir}/' and INCLTDL will be prefixed with
516 # '${top_srcdir}/' (note the single quotes!).  If your package is not
517 # flat and you're not using automake, define top_builddir and
518 # top_srcdir appropriately in the Makefiles.
519 AC_DEFUN(AC_LIBLTDL_CONVENIENCE, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
520   case "$enable_ltdl_convenience" in
521   no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
522   "") enable_ltdl_convenience=yes
523       ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
524   esac
525   LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
526   INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
527 ])
528
529 # AC_LIBLTDL_INSTALLABLE[(dir)] - sets LIBLTDL to the link flags for
530 # the libltdl installable library and INCLTDL to the include flags for
531 # the libltdl header and adds --enable-ltdl-install to the configure
532 # arguments.  Note that LIBLTDL and INCLTDL are not AC_SUBSTed, nor is
533 # AC_CONFIG_SUBDIRS called.  If DIR is not provided and an installed
534 # libltdl is not found, it is assumed to be `libltdl'.  LIBLTDL will
535 # be prefixed with '${top_builddir}/' and INCLTDL will be prefixed
536 # with '${top_srcdir}/' (note the single quotes!).  If your package is
537 # not flat and you're not using automake, define top_builddir and
538 # top_srcdir appropriately in the Makefiles.
539 # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
540 AC_DEFUN(AC_LIBLTDL_INSTALLABLE, [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
541   AC_CHECK_LIB(ltdl, main,
542   [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
543   [if test x"$enable_ltdl_install" = xno; then
544      AC_MSG_WARN([libltdl not installed, but installation disabled])
545    else
546      enable_ltdl_install=yes
547    fi
548   ])
549   if test x"$enable_ltdl_install" = x"yes"; then
550     ac_configure_args="$ac_configure_args --enable-ltdl-install"
551     LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
552     INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
553   else
554     ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
555     LIBLTDL="-lltdl"
556     INCLTDL=
557   fi
558 ])
559
560 dnl old names
561 AC_DEFUN(AM_PROG_LIBTOOL, [indir([AC_PROG_LIBTOOL])])dnl
562 AC_DEFUN(AM_ENABLE_SHARED, [indir([AC_ENABLE_SHARED], $@)])dnl
563 AC_DEFUN(AM_ENABLE_STATIC, [indir([AC_ENABLE_STATIC], $@)])dnl
564 AC_DEFUN(AM_DISABLE_SHARED, [indir([AC_DISABLE_SHARED], $@)])dnl
565 AC_DEFUN(AM_DISABLE_STATIC, [indir([AC_DISABLE_STATIC], $@)])dnl
566 AC_DEFUN(AM_PROG_LD, [indir([AC_PROG_LD])])dnl
567 AC_DEFUN(AM_PROG_NM, [indir([AC_PROG_NM])])dnl
568
569 dnl This is just to silence aclocal about the macro not being used
570 ifelse([AC_DISABLE_FAST_INSTALL])dnl
571