1 # aclocal.m4 generated automatically by aclocal 1.6.1 -*- Autoconf -*-
3 # Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
4 # Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
14 # AC_LANG_STDCALL_FUNC_LINK_TRY(FUNCTION, SIGNATURE)
15 # -------------------------------
16 # Produce a source which links correctly iff the FUNCTION exists.
17 AC_DEFUN([AC_LANG_STDCALL_FUNC_LINK_TRY],
18 [_AC_LANG_DISPATCH([$0], _AC_LANG, $@)])
20 # AC_CHECK_STDCALL_FUNC(FUNCTION, SIGNATURE, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
21 # -----------------------------------------------------------------
22 AC_DEFUN([AC_CHECK_STDCALL_FUNC],
23 [AS_VAR_PUSHDEF([ac_var], [ac_cv_func_$1])dnl
24 AC_CACHE_CHECK([for $1], ac_var,
25 [AC_LINK_IFELSE([AC_LANG_STDCALL_FUNC_LINK_TRY([$1],[$2])],
26 [AS_VAR_SET(ac_var, yes)],
27 [AS_VAR_SET(ac_var, no)])])
28 AS_IF([test AS_VAR_GET(ac_var) = yes], [$3], [$4])dnl
29 AS_VAR_POPDEF([ac_var])dnl
32 # AC_LANG_STDCALL_FUNC_LINK_TRY(C)(FUNCTION, SIGNATURE)
33 # ----------------------------------
34 # Don't include <ctype.h> because on OSF/1 3.0 it includes
35 # <sys/types.h> which includes <sys/select.h> which contains a
36 # prototype for select. Similarly for bzero.
37 m4_define([AC_LANG_STDCALL_FUNC_LINK_TRY(C)],
39 [/* System header to define __stub macros and hopefully few prototypes,
40 which can conflict with char __stdcall $1 ( $2 ) below. */
42 /* Override any gcc2 internal prototype to avoid an error. */
46 /* We use char because int might match the return type of a gcc2
47 builtin and then its argument prototype would still apply. */
48 char __stdcall $1 ( $2 );
51 [/* The GNU C library defines this for functions which it implements
52 to always fail with ENOSYS. Some functions are actually named
53 something starting with __ and the normal name is an alias. */
54 #if defined (__stub_$1) || defined (__stub___$1)
61 # AC_LANG_STDCALL_FUNC_LINK_TRY(C++)(FUNCTION)
62 # ------------------------------------
63 m4_copy([AC_LANG_STDCALL_FUNC_LINK_TRY(C)], [AC_LANG_STDCALL_FUNC_LINK_TRY(C++)])
66 # Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
68 # Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
70 # This program is free software; you can redistribute it and/or modify
71 # it under the terms of the GNU General Public License as published by
72 # the Free Software Foundation; either version 2, or (at your option)
75 # This program is distributed in the hope that it will be useful,
76 # but WITHOUT ANY WARRANTY; without even the implied warranty of
77 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
78 # GNU General Public License for more details.
80 # You should have received a copy of the GNU General Public License
81 # along with this program; if not, write to the Free Software
82 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
89 # When config.status generates a header, we must update the stamp-h file.
90 # This file resides in the same directory as the config header
91 # that is generated. We must strip everything past the first ":",
92 # and everything past the last "/".
96 # Like AS_DIRNAME, only do it during macro expansion
97 AC_DEFUN([_AM_DIRNAME],
98 [m4_if(regexp([$1], [^.*[^/]//*[^/][^/]*/*$]), -1,
99 m4_if(regexp([$1], [^//\([^/]\|$\)]), -1,
100 m4_if(regexp([$1], [^/.*]), -1,
102 patsubst([$1], [^\(/\).*], [\1])),
103 patsubst([$1], [^\(//\)\([^/].*\|$\)], [\1])),
104 patsubst([$1], [^\(.*[^/]\)//*[^/][^/]*/*$], [\1]))[]dnl
108 # The stamp files are numbered to have different names.
109 # We could number them on a directory basis, but that's additional
110 # complications, let's have a unique counter.
111 m4_define([_AM_STAMP_Count], [0])
116 # The name of the stamp file for HEADER.
117 AC_DEFUN([_AM_STAMP],
118 [m4_define([_AM_STAMP_Count], m4_incr(_AM_STAMP_Count))dnl
119 AS_ESCAPE(_AM_DIRNAME(patsubst([$1],
120 [:.*])))/stamp-h[]_AM_STAMP_Count])
123 # _AM_CONFIG_HEADER(HEADER[:SOURCES], COMMANDS, INIT-COMMANDS)
124 # ------------------------------------------------------------
125 # We used to try to get a real timestamp in stamp-h. But the fear is that
126 # that will cause unnecessary cvs conflicts.
127 AC_DEFUN([_AM_CONFIG_HEADER],
128 [# Add the stamp file to the list of files AC keeps track of,
129 # along with our hook.
130 AC_CONFIG_HEADERS([$1],
131 [# update the timestamp
132 echo 'timestamp for $1' >"_AM_STAMP([$1])"
135 ])# _AM_CONFIG_HEADER
138 # AM_CONFIG_HEADER(HEADER[:SOURCES]..., COMMANDS, INIT-COMMANDS)
139 # --------------------------------------------------------------
140 AC_DEFUN([AM_CONFIG_HEADER],
141 [AC_FOREACH([_AM_File], [$1], [_AM_CONFIG_HEADER(_AM_File, [$2], [$3])])
144 # Do all the work for Automake. -*- Autoconf -*-
146 # This macro actually does too much some checks are only needed if
147 # your package does certain things. But this isn't really a big deal.
149 # Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
150 # Free Software Foundation, Inc.
152 # This program is free software; you can redistribute it and/or modify
153 # it under the terms of the GNU General Public License as published by
154 # the Free Software Foundation; either version 2, or (at your option)
157 # This program is distributed in the hope that it will be useful,
158 # but WITHOUT ANY WARRANTY; without even the implied warranty of
159 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
160 # GNU General Public License for more details.
162 # You should have received a copy of the GNU General Public License
163 # along with this program; if not, write to the Free Software
164 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
169 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
170 # written in clear, in which case automake, when reading aclocal.m4,
171 # will think it sees a *use*, and therefore will trigger all it's
172 # C support machinery. Also note that it means that autoscan, seeing
173 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
178 # Autoconf 2.50 wants to disallow AM_ names. We explicitly allow
179 # the ones we care about.
180 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
182 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
183 # AM_INIT_AUTOMAKE([OPTIONS])
184 # -----------------------------------------------
185 # The call with PACKAGE and VERSION arguments is the old style
186 # call (pre autoconf-2.50), which is being phased out. PACKAGE
187 # and VERSION should now be passed to AC_INIT and removed from
188 # the call to AM_INIT_AUTOMAKE.
189 # We support both call styles for the transition. After
190 # the next Automake release, Autoconf can make the AC_INIT
191 # arguments mandatory, and then we can depend on a new Autoconf
192 # release and drop the old call support.
193 AC_DEFUN([AM_INIT_AUTOMAKE],
194 [AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
195 AC_REQUIRE([AC_PROG_INSTALL])dnl
196 # test to see if srcdir already configured
197 if test "`cd $srcdir && pwd`" != "`pwd`" &&
198 test -f $srcdir/config.status; then
199 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
202 # Define the identity of the package.
203 dnl Distinguish between old-style and new-style calls.
205 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
206 AC_SUBST([PACKAGE], [$1])dnl
207 AC_SUBST([VERSION], [$2])],
208 [_AM_SET_OPTIONS([$1])dnl
209 AC_SUBST([PACKAGE], [AC_PACKAGE_TARNAME])dnl
210 AC_SUBST([VERSION], [AC_PACKAGE_VERSION])])dnl
212 _AM_IF_OPTION([no-define],,
213 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
214 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
216 # Some tools Automake needs.
217 AC_REQUIRE([AM_SANITY_CHECK])dnl
218 AC_REQUIRE([AC_ARG_PROGRAM])dnl
219 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
220 AM_MISSING_PROG(AUTOCONF, autoconf)
221 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
222 AM_MISSING_PROG(AUTOHEADER, autoheader)
223 AM_MISSING_PROG(MAKEINFO, makeinfo)
224 AM_MISSING_PROG(AMTAR, tar)
226 AM_PROG_INSTALL_STRIP
227 # We need awk for the "check" target. The system "awk" is bad on
229 AC_REQUIRE([AC_PROG_AWK])dnl
230 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
232 _AM_IF_OPTION([no-dependencies],,
233 [AC_PROVIDE_IFELSE([AC_PROG_][CC],
234 [_AM_DEPENDENCIES(CC)],
235 [define([AC_PROG_][CC],
236 defn([AC_PROG_][CC])[_AM_DEPENDENCIES(CC)])])dnl
237 AC_PROVIDE_IFELSE([AC_PROG_][CXX],
238 [_AM_DEPENDENCIES(CXX)],
239 [define([AC_PROG_][CXX],
240 defn([AC_PROG_][CXX])[_AM_DEPENDENCIES(CXX)])])dnl
244 # Copyright 2002 Free Software Foundation, Inc.
246 # This program is free software; you can redistribute it and/or modify
247 # it under the terms of the GNU General Public License as published by
248 # the Free Software Foundation; either version 2, or (at your option)
251 # This program is distributed in the hope that it will be useful,
252 # but WITHOUT ANY WARRANTY; without even the implied warranty of
253 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
254 # GNU General Public License for more details.
256 # You should have received a copy of the GNU General Public License
257 # along with this program; if not, write to the Free Software
258 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
260 # AM_AUTOMAKE_VERSION(VERSION)
261 # ----------------------------
262 # Automake X.Y traces this macro to ensure aclocal.m4 has been
263 # generated from the m4 files accompanying Automake X.Y.
264 AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.6"])
266 # AM_SET_CURRENT_AUTOMAKE_VERSION
267 # -------------------------------
268 # Call AM_AUTOMAKE_VERSION so it can be traced.
269 # This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
270 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
271 [AM_AUTOMAKE_VERSION([1.6.1])])
273 # Helper functions for option handling. -*- Autoconf -*-
275 # Copyright 2001, 2002 Free Software Foundation, Inc.
277 # This program is free software; you can redistribute it and/or modify
278 # it under the terms of the GNU General Public License as published by
279 # the Free Software Foundation; either version 2, or (at your option)
282 # This program is distributed in the hope that it will be useful,
283 # but WITHOUT ANY WARRANTY; without even the implied warranty of
284 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
285 # GNU General Public License for more details.
287 # You should have received a copy of the GNU General Public License
288 # along with this program; if not, write to the Free Software
289 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
294 # _AM_MANGLE_OPTION(NAME)
295 # -----------------------
296 AC_DEFUN([_AM_MANGLE_OPTION],
297 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
299 # _AM_SET_OPTION(NAME)
300 # ------------------------------
301 # Set option NAME. Presently that only means defining a flag for this option.
302 AC_DEFUN([_AM_SET_OPTION],
303 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
305 # _AM_SET_OPTIONS(OPTIONS)
306 # ----------------------------------
307 # OPTIONS is a space-separated list of Automake options.
308 AC_DEFUN([_AM_SET_OPTIONS],
309 [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
311 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
312 # -------------------------------------------
313 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
314 AC_DEFUN([_AM_IF_OPTION],
315 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
318 # Check to make sure that the build environment is sane.
321 # Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
323 # This program is free software; you can redistribute it and/or modify
324 # it under the terms of the GNU General Public License as published by
325 # the Free Software Foundation; either version 2, or (at your option)
328 # This program is distributed in the hope that it will be useful,
329 # but WITHOUT ANY WARRANTY; without even the implied warranty of
330 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
331 # GNU General Public License for more details.
333 # You should have received a copy of the GNU General Public License
334 # along with this program; if not, write to the Free Software
335 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
342 AC_DEFUN([AM_SANITY_CHECK],
343 [AC_MSG_CHECKING([whether build environment is sane])
346 echo timestamp > conftest.file
347 # Do `set' in a subshell so we don't clobber the current shell's
348 # arguments. Must try -L first in case configure is actually a
349 # symlink; some systems play weird games with the mod time of symlinks
350 # (eg FreeBSD returns the mod time of the symlink's containing
353 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
354 if test "$[*]" = "X"; then
356 set X `ls -t $srcdir/configure conftest.file`
359 if test "$[*]" != "X $srcdir/configure conftest.file" \
360 && test "$[*]" != "X conftest.file $srcdir/configure"; then
362 # If neither matched, then we have a broken ls. This can happen
363 # if, for instance, CONFIG_SHELL is bash and it inherits a
364 # broken ls alias from the environment. This has actually
365 # happened. Such a system could not be considered "sane".
366 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
367 alias in your environment])
370 test "$[2]" = conftest.file
376 AC_MSG_ERROR([newly created file is older than distributed files!
377 Check your system clock])
384 # Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
386 # This program is free software; you can redistribute it and/or modify
387 # it under the terms of the GNU General Public License as published by
388 # the Free Software Foundation; either version 2, or (at your option)
391 # This program is distributed in the hope that it will be useful,
392 # but WITHOUT ANY WARRANTY; without even the implied warranty of
393 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
394 # GNU General Public License for more details.
396 # You should have received a copy of the GNU General Public License
397 # along with this program; if not, write to the Free Software
398 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
403 # AM_MISSING_PROG(NAME, PROGRAM)
404 # ------------------------------
405 AC_DEFUN([AM_MISSING_PROG],
406 [AC_REQUIRE([AM_MISSING_HAS_RUN])
407 $1=${$1-"${am_missing_run}$2"}
413 # Define MISSING if not defined so far and test if it supports --run.
414 # If it does, set am_missing_run to use it, otherwise, to nothing.
415 AC_DEFUN([AM_MISSING_HAS_RUN],
416 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
417 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
418 # Use eval to expand $SHELL
419 if eval "$MISSING --run true"; then
420 am_missing_run="$MISSING --run "
423 AC_MSG_WARN([`missing' script is too old or missing])
429 # Copyright 2001 Free Software Foundation, Inc.
431 # This program is free software; you can redistribute it and/or modify
432 # it under the terms of the GNU General Public License as published by
433 # the Free Software Foundation; either version 2, or (at your option)
436 # This program is distributed in the hope that it will be useful,
437 # but WITHOUT ANY WARRANTY; without even the implied warranty of
438 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
439 # GNU General Public License for more details.
441 # You should have received a copy of the GNU General Public License
442 # along with this program; if not, write to the Free Software
443 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
446 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
447 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
448 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
450 # Of course, Automake must honor this variable whenever it calls a
451 # tool from the auxiliary directory. The problem is that $srcdir (and
452 # therefore $ac_aux_dir as well) can be either absolute or relative,
453 # depending on how configure is run. This is pretty annoying, since
454 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
455 # source directory, any form will work fine, but in subdirectories a
456 # relative path needs to be adjusted first.
458 # $ac_aux_dir/missing
459 # fails when called from a subdirectory if $ac_aux_dir is relative
460 # $top_srcdir/$ac_aux_dir/missing
461 # fails if $ac_aux_dir is absolute,
462 # fails when called from a subdirectory in a VPATH build with
463 # a relative $ac_aux_dir
465 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
466 # are both prefixed by $srcdir. In an in-source build this is usually
467 # harmless because $srcdir is `.', but things will broke when you
468 # start a VPATH build or use an absolute $srcdir.
470 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
471 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
472 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
473 # and then we would define $MISSING as
474 # MISSING="\${SHELL} $am_aux_dir/missing"
475 # This will work as long as MISSING is not called from configure, because
476 # unfortunately $(top_srcdir) has no meaning in configure.
477 # However there are other variables, like CC, which are often used in
478 # configure, and could therefore not use this "fixed" $ac_aux_dir.
480 # Another solution, used here, is to always expand $ac_aux_dir to an
481 # absolute PATH. The drawback is that using absolute paths prevent a
482 # configured tree to be moved without reconfiguration.
484 # Rely on autoconf to set up CDPATH properly.
487 AC_DEFUN([AM_AUX_DIR_EXPAND], [
488 # expand $ac_aux_dir to an absolute path
489 am_aux_dir=`cd $ac_aux_dir && pwd`
494 # Define $install_sh.
496 # Copyright 2001 Free Software Foundation, Inc.
498 # This program is free software; you can redistribute it and/or modify
499 # it under the terms of the GNU General Public License as published by
500 # the Free Software Foundation; either version 2, or (at your option)
503 # This program is distributed in the hope that it will be useful,
504 # but WITHOUT ANY WARRANTY; without even the implied warranty of
505 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
506 # GNU General Public License for more details.
508 # You should have received a copy of the GNU General Public License
509 # along with this program; if not, write to the Free Software
510 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
513 AC_DEFUN([AM_PROG_INSTALL_SH],
514 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
515 install_sh=${install_sh-"$am_aux_dir/install-sh"}
516 AC_SUBST(install_sh)])
518 # AM_PROG_INSTALL_STRIP
520 # Copyright 2001 Free Software Foundation, Inc.
522 # This program is free software; you can redistribute it and/or modify
523 # it under the terms of the GNU General Public License as published by
524 # the Free Software Foundation; either version 2, or (at your option)
527 # This program is distributed in the hope that it will be useful,
528 # but WITHOUT ANY WARRANTY; without even the implied warranty of
529 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
530 # GNU General Public License for more details.
532 # You should have received a copy of the GNU General Public License
533 # along with this program; if not, write to the Free Software
534 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
537 # One issue with vendor `install' (even GNU) is that you can't
538 # specify the program used to strip binaries. This is especially
539 # annoying in cross-compiling environments, where the build's strip
540 # is unlikely to handle the host's binaries.
541 # Fortunately install-sh will honor a STRIPPROG variable, so we
542 # always use install-sh in `make install-strip', and initialize
543 # STRIPPROG with the value of the STRIP variable (set by the user).
544 AC_DEFUN([AM_PROG_INSTALL_STRIP],
545 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
546 # Installed binaries are usually stripped using `strip' when the user
547 # run `make install-strip'. However `strip' might not be the right
548 # tool to use in cross-compilation environments, therefore Automake
549 # will honor the `STRIP' environment variable to overrule this program.
550 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
551 if test "$cross_compiling" != no; then
552 AC_CHECK_TOOL([STRIP], [strip], :)
554 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
555 AC_SUBST([INSTALL_STRIP_PROGRAM])])
557 # serial 4 -*- Autoconf -*-
559 # Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
561 # This program is free software; you can redistribute it and/or modify
562 # it under the terms of the GNU General Public License as published by
563 # the Free Software Foundation; either version 2, or (at your option)
566 # This program is distributed in the hope that it will be useful,
567 # but WITHOUT ANY WARRANTY; without even the implied warranty of
568 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
569 # GNU General Public License for more details.
571 # You should have received a copy of the GNU General Public License
572 # along with this program; if not, write to the Free Software
573 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
577 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
578 # written in clear, in which case automake, when reading aclocal.m4,
579 # will think it sees a *use*, and therefore will trigger all it's
580 # C support machinery. Also note that it means that autoscan, seeing
581 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
585 # _AM_DEPENDENCIES(NAME)
586 # ----------------------
587 # See how the compiler implements dependency checking.
588 # NAME is "CC", "CXX", "GCJ", or "OBJC".
589 # We try a few techniques and use that to set a single cache variable.
591 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
592 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
593 # dependency, and given that the user is not expected to run this macro,
594 # just rely on AC_PROG_CC.
595 AC_DEFUN([_AM_DEPENDENCIES],
596 [AC_REQUIRE([AM_SET_DEPDIR])dnl
597 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
598 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
599 AC_REQUIRE([AM_DEP_TRACK])dnl
601 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
602 [$1], CXX, [depcc="$CXX" am_compiler_list=],
603 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc']
604 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
605 [depcc="$$1" am_compiler_list=])
607 AC_CACHE_CHECK([dependency style of $depcc],
608 [am_cv_$1_dependencies_compiler_type],
609 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
610 # We make a subdir and do the tests there. Otherwise we can end up
611 # making bogus files that we don't know about and never remove. For
612 # instance it was reported that on HP-UX the gcc test will end up
613 # making a dummy file named `D' -- because `-MD' means `put the output
616 # Copy depcomp to subdir because otherwise we won't find it if we're
617 # using a relative directory.
618 cp "$am_depcomp" conftest.dir
621 am_cv_$1_dependencies_compiler_type=none
622 if test "$am_compiler_list" = ""; then
623 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
625 for depmode in $am_compiler_list; do
626 # We need to recreate these files for each test, as the compiler may
627 # overwrite some of them when testing with obscure command lines.
628 # This happens at least with the AIX C compiler.
629 echo '#include "conftest.h"' > conftest.c
630 echo 'int i;' > conftest.h
631 echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf
635 # after this tag, mechanisms are not by side-effect, so they'll
636 # only be used when explicitly requested
637 if test "x$enable_dependency_tracking" = xyes; then
645 # We check with `-c' and `-o' for the sake of the "dashmstdout"
646 # mode. It turns out that the SunPro C++ compiler does not properly
647 # handle `-M -o', and we need to detect this.
648 if depmode=$depmode \
649 source=conftest.c object=conftest.o \
650 depfile=conftest.Po tmpdepfile=conftest.TPo \
651 $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
652 grep conftest.h conftest.Po > /dev/null 2>&1 &&
653 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
654 am_cv_$1_dependencies_compiler_type=$depmode
662 am_cv_$1_dependencies_compiler_type=none
665 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
671 # Choose a directory name for dependency files.
672 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
673 AC_DEFUN([AM_SET_DEPDIR],
674 [rm -f .deps 2>/dev/null
675 mkdir .deps 2>/dev/null
676 if test -d .deps; then
679 # MS-DOS does not allow filenames that begin with a dot.
682 rmdir .deps 2>/dev/null
689 AC_DEFUN([AM_DEP_TRACK],
690 [AC_ARG_ENABLE(dependency-tracking,
691 [ --disable-dependency-tracking Speeds up one-time builds
692 --enable-dependency-tracking Do not reject slow dependency extractors])
693 if test "x$enable_dependency_tracking" != xno; then
694 am_depcomp="$ac_aux_dir/depcomp"
697 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
698 AC_SUBST([AMDEPBACKSLASH])
701 # Generate code to set up dependency tracking. -*- Autoconf -*-
703 # Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
705 # This program is free software; you can redistribute it and/or modify
706 # it under the terms of the GNU General Public License as published by
707 # the Free Software Foundation; either version 2, or (at your option)
710 # This program is distributed in the hope that it will be useful,
711 # but WITHOUT ANY WARRANTY; without even the implied warranty of
712 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
713 # GNU General Public License for more details.
715 # You should have received a copy of the GNU General Public License
716 # along with this program; if not, write to the Free Software
717 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
722 # _AM_OUTPUT_DEPENDENCY_COMMANDS
723 # ------------------------------
724 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
725 [for mf in $CONFIG_FILES; do
726 # Strip MF so we end up with the name of the file.
727 mf=`echo "$mf" | sed -e 's/:.*$//'`
728 if (sed 1q $mf | fgrep 'generated by automake') > /dev/null 2>&1; then
729 dirpart=`AS_DIRNAME("$mf")`
733 grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
734 # Extract the definition of DEP_FILES from the Makefile without
736 DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
737 test -z "$DEPDIR" && continue
738 # When using ansi2knr, U may be empty or an underscore; expand it
739 U=`sed -n -e '/^U = / s///p' < "$mf"`
740 test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
741 # We invoke sed twice because it is the simplest approach to
742 # changing $(DEPDIR) to its actual value in the expansion.
743 for file in `sed -n -e '
744 /^DEP_FILES = .*\\\\$/ {
753 /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
754 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
755 # Make sure the directory exists.
756 test -f "$dirpart/$file" && continue
757 fdir=`AS_DIRNAME(["$file"])`
758 AS_MKDIR_P([$dirpart/$fdir])
759 # echo "creating $dirpart/$file"
760 echo '# dummy' > "$dirpart/$file"
763 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
766 # AM_OUTPUT_DEPENDENCY_COMMANDS
767 # -----------------------------
768 # This macro should only be invoked once -- use via AC_REQUIRE.
770 # This code is only required when automatic dependency tracking
771 # is enabled. FIXME. This creates each `.P' file that we will
772 # need in order to bootstrap the dependency handling code.
773 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
774 [AC_CONFIG_COMMANDS([depfiles],
775 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
776 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
779 # Copyright 2001 Free Software Foundation, Inc. -*- Autoconf -*-
781 # This program is free software; you can redistribute it and/or modify
782 # it under the terms of the GNU General Public License as published by
783 # the Free Software Foundation; either version 2, or (at your option)
786 # This program is distributed in the hope that it will be useful,
787 # but WITHOUT ANY WARRANTY; without even the implied warranty of
788 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
789 # GNU General Public License for more details.
791 # You should have received a copy of the GNU General Public License
792 # along with this program; if not, write to the Free Software
793 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
800 # Check to see how make treats includes.
801 AC_DEFUN([AM_MAKE_INCLUDE],
802 [am_make=${MAKE-make}
803 cat > confinc << 'END'
807 # If we don't find an include directive, just comment out the code.
808 AC_MSG_CHECKING([for style of include used by $am_make])
812 # First try GNU make style include.
813 echo "include confinc" > confmf
814 # We grep out `Entering directory' and `Leaving directory'
815 # messages which can occur if `w' ends up in MAKEFLAGS.
816 # In particular we don't look at `^make:' because GNU make might
817 # be invoked under some other name (usually "gmake"), in which
818 # case it prints its new name instead of `make'.
819 if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then
824 # Now try BSD make style include.
825 if test "$am__include" = "#"; then
826 echo '.include "confinc"' > confmf
827 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
833 AC_SUBST(am__include)
835 AC_MSG_RESULT($_am_result)
839 # AM_CONDITIONAL -*- Autoconf -*-
841 # Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
843 # This program is free software; you can redistribute it and/or modify
844 # it under the terms of the GNU General Public License as published by
845 # the Free Software Foundation; either version 2, or (at your option)
848 # This program is distributed in the hope that it will be useful,
849 # but WITHOUT ANY WARRANTY; without even the implied warranty of
850 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
851 # GNU General Public License for more details.
853 # You should have received a copy of the GNU General Public License
854 # along with this program; if not, write to the Free Software
855 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
862 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
863 # -------------------------------------
864 # Define a conditional.
865 AC_DEFUN([AM_CONDITIONAL],
866 [ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
867 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
877 AC_CONFIG_COMMANDS_PRE(
878 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
879 AC_MSG_ERROR([conditional \"$1\" was never defined.
880 Usually this means the macro was only invoked conditionally.])
883 # Add --enable-maintainer-mode option to configure.
886 # Copyright 1996, 1998, 2000, 2001 Free Software Foundation, Inc.
888 # This program is free software; you can redistribute it and/or modify
889 # it under the terms of the GNU General Public License as published by
890 # the Free Software Foundation; either version 2, or (at your option)
893 # This program is distributed in the hope that it will be useful,
894 # but WITHOUT ANY WARRANTY; without even the implied warranty of
895 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
896 # GNU General Public License for more details.
898 # You should have received a copy of the GNU General Public License
899 # along with this program; if not, write to the Free Software
900 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
905 AC_DEFUN([AM_MAINTAINER_MODE],
906 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
907 dnl maintainer-mode is disabled by default
908 AC_ARG_ENABLE(maintainer-mode,
909 [ --enable-maintainer-mode enable make rules and dependencies not useful
910 (and sometimes confusing) to the casual installer],
911 USE_MAINTAINER_MODE=$enableval,
912 USE_MAINTAINER_MODE=no)
913 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
914 AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
915 MAINT=$MAINTAINER_MODE_TRUE