1dnl aclocal.m4 generated automatically by aclocal 1.4 2 3dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc. 4dnl This file is free software; the Free Software Foundation 5dnl gives unlimited permission to copy and/or distribute it, 6dnl with or without modifications, as long as this notice is preserved. 7 8dnl This program is distributed in the hope that it will be useful, 9dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without 10dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A 11dnl PARTICULAR PURPOSE. 12 13dnl cloned from autoconf 2.13 acspecific.m4 14AC_DEFUN(AC_C_LONG_LONG, 15[AC_CACHE_CHECK(for long long, ac_cv_c_long_long, 16[if test "$GCC" = yes; then 17 ac_cv_c_long_long=yes 18else 19AC_TRY_RUN([int main() { 20long long foo = 0; 21exit(sizeof(long long) < sizeof(long)); }], 22ac_cv_c_long_long=yes, ac_cv_c_long_long=no) 23fi]) 24if test $ac_cv_c_long_long = yes; then 25 AC_DEFINE(HAVE_LONG_LONG) 26fi 27]) 28 29dnl from autoconf 2.13 acgeneral.m4, with patch: 30dnl Date: Fri, 15 Jan 1999 05:52:41 -0800 31dnl Message-ID: <199901151352.FAA18237@shade.twinsun.com> 32dnl From: eggert@twinsun.com (Paul Eggert) 33dnl Subject: autoconf 2.13 AC_CHECK_TYPE doesn't allow shell vars 34dnl Newsgroups: gnu.utils.bug 35 36dnl AC_CHECK_TYPE2(TYPE, DEFAULT) 37AC_DEFUN(AC_CHECK_TYPE2, 38[AC_REQUIRE([AC_HEADER_STDC])dnl 39AC_MSG_CHECKING(for $1) 40AC_CACHE_VAL(ac_cv_type_$1, 41[AC_EGREP_CPP(dnl 42changequote(<<,>>)dnl 43<<(^|[^a-zA-Z_0-9])$1[^a-zA-Z_0-9]>>dnl 44changequote([,]), [#include <sys/types.h> 45#if STDC_HEADERS 46#include <stdlib.h> 47#include <stddef.h> 48#endif], eval "ac_cv_type_$1=yes", eval "ac_cv_type_$1=no")])dnl 49if eval "test \"`echo '$ac_cv_type_'$1`\" = yes"; then 50 AC_MSG_RESULT(yes) 51else 52 AC_MSG_RESULT(no) 53 AC_DEFINE_UNQUOTED($1, $2) 54fi 55]) 56 57dnl from autoconf 2.13 acgeneral.m4, with additional third argument 58dnl AC_CHECK_SIZEOF_INCLUDES(TYPE [, CROSS-SIZE, [INCLUDES]]) 59AC_DEFUN(AC_CHECK_SIZEOF_INCLUDES, 60[changequote(<<, >>)dnl 61dnl The name to #define. 62define(<<AC_TYPE_NAME>>, translit(sizeof_$1, [a-z *], [A-Z_P]))dnl 63dnl The cache variable name. 64define(<<AC_CV_NAME>>, translit(ac_cv_sizeof_$1, [ *], [_p]))dnl 65changequote([, ])dnl 66AC_MSG_CHECKING(size of $1) 67AC_CACHE_VAL(AC_CV_NAME, 68[AC_TRY_RUN([$3 69#include <stdio.h> 70main() 71{ 72 FILE *f=fopen("conftestval", "w"); 73 if (!f) exit(1); 74 fprintf(f, "%d\n", sizeof($1)); 75 exit(0); 76}], AC_CV_NAME=`cat conftestval`, AC_CV_NAME=0, ifelse([$2], , , AC_CV_NAME=$2))])dnl 77AC_MSG_RESULT($AC_CV_NAME) 78AC_DEFINE_UNQUOTED(AC_TYPE_NAME, $AC_CV_NAME) 79undefine([AC_TYPE_NAME])dnl 80undefine([AC_CV_NAME])dnl 81]) 82 83dnl AC_CHECK_SIZEOF_STDC_HEADERS(TYPE [, CROSS_SIZE]) 84AC_DEFUN(AC_CHECK_SIZEOF_STDC_HEADERS, 85[AC_CHECK_SIZEOF_INCLUDES($1, $2, 86[#include <sys/types.h> 87#ifdef STDC_HEADERS 88#include <stdlib.h> 89#endif 90]) 91]) 92 93# Do all the work for Automake. This macro actually does too much -- 94# some checks are only needed if your package does certain things. 95# But this isn't really a big deal. 96 97# serial 1 98 99dnl Usage: 100dnl AM_INIT_AUTOMAKE(package,version, [no-define]) 101 102AC_DEFUN(AM_INIT_AUTOMAKE, 103[AC_REQUIRE([AC_PROG_INSTALL]) 104PACKAGE=[$1] 105AC_SUBST(PACKAGE) 106VERSION=[$2] 107AC_SUBST(VERSION) 108dnl test to see if srcdir already configured 109if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then 110 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 111fi 112ifelse([$3],, 113AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 114AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])) 115AC_REQUIRE([AM_SANITY_CHECK]) 116AC_REQUIRE([AC_ARG_PROGRAM]) 117dnl FIXME This is truly gross. 118missing_dir=`cd $ac_aux_dir && pwd` 119AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir) 120AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir) 121AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir) 122AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir) 123AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir) 124AC_REQUIRE([AC_PROG_MAKE_SET])]) 125 126# 127# Check to make sure that the build environment is sane. 128# 129 130AC_DEFUN(AM_SANITY_CHECK, 131[AC_MSG_CHECKING([whether build environment is sane]) 132# Just in case 133sleep 1 134echo timestamp > conftestfile 135# Do `set' in a subshell so we don't clobber the current shell's 136# arguments. Must try -L first in case configure is actually a 137# symlink; some systems play weird games with the mod time of symlinks 138# (eg FreeBSD returns the mod time of the symlink's containing 139# directory). 140if ( 141 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` 142 if test "[$]*" = "X"; then 143 # -L didn't work. 144 set X `ls -t $srcdir/configure conftestfile` 145 fi 146 if test "[$]*" != "X $srcdir/configure conftestfile" \ 147 && test "[$]*" != "X conftestfile $srcdir/configure"; then 148 149 # If neither matched, then we have a broken ls. This can happen 150 # if, for instance, CONFIG_SHELL is bash and it inherits a 151 # broken ls alias from the environment. This has actually 152 # happened. Such a system could not be considered "sane". 153 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 154alias in your environment]) 155 fi 156 157 test "[$]2" = conftestfile 158 ) 159then 160 # Ok. 161 : 162else 163 AC_MSG_ERROR([newly created file is older than distributed files! 164Check your system clock]) 165fi 166rm -f conftest* 167AC_MSG_RESULT(yes)]) 168 169dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY) 170dnl The program must properly implement --version. 171AC_DEFUN(AM_MISSING_PROG, 172[AC_MSG_CHECKING(for working $2) 173# Run test in a subshell; some versions of sh will print an error if 174# an executable is not found, even if stderr is redirected. 175# Redirect stdin to placate older versions of autoconf. Sigh. 176if ($2 --version) < /dev/null > /dev/null 2>&1; then 177 $1=$2 178 AC_MSG_RESULT(found) 179else 180 $1="$3/missing $2" 181 AC_MSG_RESULT(missing) 182fi 183AC_SUBST($1)]) 184 185# Like AC_CONFIG_HEADER, but automatically create stamp file. 186 187AC_DEFUN(AM_CONFIG_HEADER, 188[AC_PREREQ([2.12]) 189AC_CONFIG_HEADER([$1]) 190dnl When config.status generates a header, we must update the stamp-h file. 191dnl This file resides in the same directory as the config header 192dnl that is generated. We must strip everything past the first ":", 193dnl and everything past the last "/". 194AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl 195ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>, 196<<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>, 197<<am_indx=1 198for am_file in <<$1>>; do 199 case " <<$>>CONFIG_HEADERS " in 200 *" <<$>>am_file "*<<)>> 201 echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx 202 ;; 203 esac 204 am_indx=`expr "<<$>>am_indx" + 1` 205done<<>>dnl>>) 206changequote([,]))]) 207 208