1 dnl aclocal.m4 generated automatically by aclocal 1.4-p5
3 dnl Copyright (C) 1994, 1995-8, 1999, 2001 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.
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.
13 sinclude(../config/accross.m4)
15 dnl Define MKDIR_TAKES_ONE_ARG if mkdir accepts only one argument instead
17 AC_DEFUN(gcc_AC_FUNC_MKDIR_TAKES_ONE_ARG,
18 [AC_CACHE_CHECK([if mkdir takes one argument], gcc_cv_mkdir_takes_one_arg,
20 #include <sys/types.h>
21 #ifdef HAVE_SYS_STAT_H
22 # include <sys/stat.h>
29 #endif], [mkdir ("foo", 0);],
30 gcc_cv_mkdir_takes_one_arg=no, gcc_cv_mkdir_takes_one_arg=yes)])
31 if test $gcc_cv_mkdir_takes_one_arg = yes ; then
32 AC_DEFINE(MKDIR_TAKES_ONE_ARG, 1, [Define if host mkdir takes a
37 # Do all the work for Automake. This macro actually does too much --
38 # some checks are only needed if your package does certain things.
39 # But this isn't really a big deal.
44 dnl AM_INIT_AUTOMAKE(package,version, [no-define])
46 AC_DEFUN([AM_INIT_AUTOMAKE],
47 [AC_REQUIRE([AC_PROG_INSTALL])
52 dnl test to see if srcdir already configured
53 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
54 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
57 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
58 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
59 AC_REQUIRE([AM_SANITY_CHECK])
60 AC_REQUIRE([AC_ARG_PROGRAM])
61 dnl FIXME This is truly gross.
62 missing_dir=`cd $ac_aux_dir && pwd`
63 AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
64 AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
65 AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
66 AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
67 AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
68 AC_REQUIRE([AC_PROG_MAKE_SET])])
71 # Check to make sure that the build environment is sane.
74 AC_DEFUN([AM_SANITY_CHECK],
75 [AC_MSG_CHECKING([whether build environment is sane])
78 echo timestamp > conftestfile
79 # Do `set' in a subshell so we don't clobber the current shell's
80 # arguments. Must try -L first in case configure is actually a
81 # symlink; some systems play weird games with the mod time of symlinks
82 # (eg FreeBSD returns the mod time of the symlink's containing
85 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
86 if test "[$]*" = "X"; then
88 set X `ls -t $srcdir/configure conftestfile`
90 if test "[$]*" != "X $srcdir/configure conftestfile" \
91 && test "[$]*" != "X conftestfile $srcdir/configure"; then
93 # If neither matched, then we have a broken ls. This can happen
94 # if, for instance, CONFIG_SHELL is bash and it inherits a
95 # broken ls alias from the environment. This has actually
96 # happened. Such a system could not be considered "sane".
97 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
98 alias in your environment])
101 test "[$]2" = conftestfile
107 AC_MSG_ERROR([newly created file is older than distributed files!
108 Check your system clock])
113 dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
114 dnl The program must properly implement --version.
115 AC_DEFUN([AM_MISSING_PROG],
116 [AC_MSG_CHECKING(for working $2)
117 # Run test in a subshell; some versions of sh will print an error if
118 # an executable is not found, even if stderr is redirected.
119 # Redirect stdin to placate older versions of autoconf. Sigh.
120 if ($2 --version) < /dev/null > /dev/null 2>&1; then
125 AC_MSG_RESULT(missing)
129 # Like AC_CONFIG_HEADER, but automatically create stamp file.
131 AC_DEFUN([AM_CONFIG_HEADER],
133 AC_CONFIG_HEADER([$1])
134 dnl When config.status generates a header, we must update the stamp-h file.
135 dnl This file resides in the same directory as the config header
136 dnl that is generated. We must strip everything past the first ":",
137 dnl and everything past the last "/".
138 AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
139 ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
140 <<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
142 for am_file in <<$1>>; do
143 case " <<$>>CONFIG_HEADERS " in
144 *" <<$>>am_file "*<<)>>
145 echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
148 am_indx=`expr "<<$>>am_indx" + 1`
152 # Add --enable-maintainer-mode option to configure.
157 AC_DEFUN([AM_MAINTAINER_MODE],
158 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
159 dnl maintainer-mode is disabled by default
160 AC_ARG_ENABLE(maintainer-mode,
161 [ --enable-maintainer-mode enable make rules and dependencies not useful
162 (and sometimes confusing) to the casual installer],
163 USE_MAINTAINER_MODE=$enableval,
164 USE_MAINTAINER_MODE=no)
165 AC_MSG_RESULT($USE_MAINTAINER_MODE)
166 AM_CONDITIONAL(MAINTAINER_MODE, test $USE_MAINTAINER_MODE = yes)
167 MAINT=$MAINTAINER_MODE_TRUE
172 # Define a conditional.
174 AC_DEFUN([AM_CONDITIONAL],