| 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 | # FIXME: We temporarily define our own version of AC_PROG_CC. This is
|
|---|
| 14 | # copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS. We
|
|---|
| 15 | # are probably using a cross compiler, which will not be able to fully
|
|---|
| 16 | # link an executable. This should really be fixed in autoconf
|
|---|
| 17 | # itself.
|
|---|
| 18 |
|
|---|
| 19 | AC_DEFUN(LIB_AC_PROG_CC,
|
|---|
| 20 | [AC_BEFORE([$0], [AC_PROG_CPP])dnl
|
|---|
| 21 | dnl Fool anybody using AC_PROG_CC.
|
|---|
| 22 | AC_PROVIDE([AC_PROG_CC])
|
|---|
| 23 | AC_CHECK_PROG(CC, gcc, gcc)
|
|---|
| 24 | if test -z "$CC"; then
|
|---|
| 25 | AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
|
|---|
| 26 | test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
|
|---|
| 27 | fi
|
|---|
| 28 |
|
|---|
| 29 | AC_PROG_CC_GNU
|
|---|
| 30 |
|
|---|
| 31 | if test $ac_cv_prog_gcc = yes; then
|
|---|
| 32 | GCC=yes
|
|---|
| 33 | dnl Check whether -g works, even if CFLAGS is set, in case the package
|
|---|
| 34 | dnl plays around with CFLAGS (such as to build both debugging and
|
|---|
| 35 | dnl normal versions of a library), tasteless as that idea is.
|
|---|
| 36 | ac_test_CFLAGS="${CFLAGS+set}"
|
|---|
| 37 | ac_save_CFLAGS="$CFLAGS"
|
|---|
| 38 | CFLAGS=
|
|---|
| 39 | AC_PROG_CC_G
|
|---|
| 40 | if test "$ac_test_CFLAGS" = set; then
|
|---|
| 41 | CFLAGS="$ac_save_CFLAGS"
|
|---|
| 42 | elif test $ac_cv_prog_cc_g = yes; then
|
|---|
| 43 | CFLAGS="-g -O2"
|
|---|
| 44 | else
|
|---|
| 45 | CFLAGS="-O2"
|
|---|
| 46 | fi
|
|---|
| 47 | else
|
|---|
| 48 | GCC=
|
|---|
| 49 | test "${CFLAGS+set}" = set || CFLAGS="-g"
|
|---|
| 50 | fi
|
|---|
| 51 | ])
|
|---|
| 52 |
|
|---|
| 53 | sinclude(../libtool.m4)
|
|---|
| 54 | dnl The lines below arrange for aclocal not to bring libtool.m4
|
|---|
| 55 | dnl AM_PROG_LIBTOOL into aclocal.m4, while still arranging for automake
|
|---|
| 56 | dnl to add a definition of LIBTOOL to Makefile.in.
|
|---|
| 57 | ifelse(yes,no,[
|
|---|
| 58 | AC_DEFUN([AM_PROG_LIBTOOL],)
|
|---|
| 59 | AC_SUBST(LIBTOOL)
|
|---|
| 60 | ])
|
|---|
| 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 | # Add --enable-maintainer-mode option to configure.
|
|---|
| 155 | # From Jim Meyering
|
|---|
| 156 |
|
|---|
| 157 | # serial 1
|
|---|
| 158 |
|
|---|
| 159 | AC_DEFUN(AM_MAINTAINER_MODE,
|
|---|
| 160 | [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
|
|---|
| 161 | dnl maintainer-mode is disabled by default
|
|---|
| 162 | AC_ARG_ENABLE(maintainer-mode,
|
|---|
| 163 | [ --enable-maintainer-mode enable make rules and dependencies not useful
|
|---|
| 164 | (and sometimes confusing) to the casual installer],
|
|---|
| 165 | USE_MAINTAINER_MODE=$enableval,
|
|---|
| 166 | USE_MAINTAINER_MODE=no)
|
|---|
| 167 | AC_MSG_RESULT($USE_MAINTAINER_MODE)
|
|---|
| 168 | AM_CONDITIONAL(MAINTAINER_MODE, test $USE_MAINTAINER_MODE = yes)
|
|---|
| 169 | MAINT=$MAINTAINER_MODE_TRUE
|
|---|
| 170 | AC_SUBST(MAINT)dnl
|
|---|
| 171 | ]
|
|---|
| 172 | )
|
|---|
| 173 |
|
|---|
| 174 | # Define a conditional.
|
|---|
| 175 |
|
|---|
| 176 | AC_DEFUN(AM_CONDITIONAL,
|
|---|
| 177 | [AC_SUBST($1_TRUE)
|
|---|
| 178 | AC_SUBST($1_FALSE)
|
|---|
| 179 | if $2; then
|
|---|
| 180 | $1_TRUE=
|
|---|
| 181 | $1_FALSE='#'
|
|---|
| 182 | else
|
|---|
| 183 | $1_TRUE='#'
|
|---|
| 184 | $1_FALSE=
|
|---|
| 185 | fi])
|
|---|
| 186 |
|
|---|