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 13AC_DEFUN(FIGURINE_EXTRA_PATHS, 14[ 15 16AC_ARG_WITH(extra-includes, 17[ --with-extra-includes=DIR 18 add extra include paths], 19 use_extra_includes="$withval", 20 use_extra_includes=NO 21) 22if test -n "$use_extra_includes" && \ 23 test "$use_extra_includes" != "NO"; then 24 ac_save_ifs=$IFS 25 IFS=':' 26 for dir in $use_extra_includes; do 27 extra_includes="$extra_includes -I$dir" 28 done 29 IFS=$ac_save_ifs 30 CPPFLAGS="$CPPFLAGS $extra_includes" 31fi 32 33AC_ARG_WITH(extra-libs, 34[ --with-extra-libs=DIR add extra library paths], 35 use_extra_libs=$withval, 36 use_extra_libs=NO 37) 38if test -n "$use_extra_libs" && \ 39 test "$use_extra_libs" != "NO"; then 40 ac_save_ifs=$IFS 41 IFS=':' 42 for dir in $use_extra_libs; do 43 extra_libraries="$extra_libraries -L$dir" 44 done 45 IFS=$ac_save_ifs 46fi 47 48AC_SUBST(extra_includes) 49AC_SUBST(extra_libraries) 50 51]) 52 53 54# Do all the work for Automake. This macro actually does too much -- 55# some checks are only needed if your package does certain things. 56# But this isn't really a big deal. 57 58# serial 1 59 60dnl Usage: 61dnl AM_INIT_AUTOMAKE(package,version, [no-define]) 62 63AC_DEFUN(AM_INIT_AUTOMAKE, 64[AC_REQUIRE([AC_PROG_INSTALL]) 65PACKAGE=[$1] 66AC_SUBST(PACKAGE) 67VERSION=[$2] 68AC_SUBST(VERSION) 69dnl test to see if srcdir already configured 70if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then 71 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 72fi 73ifelse([$3],, 74AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 75AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])) 76AC_REQUIRE([AM_SANITY_CHECK]) 77AC_REQUIRE([AC_ARG_PROGRAM]) 78dnl FIXME This is truly gross. 79missing_dir=`cd $ac_aux_dir && pwd` 80AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir) 81AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir) 82AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir) 83AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir) 84AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir) 85AC_REQUIRE([AC_PROG_MAKE_SET])]) 86 87# 88# Check to make sure that the build environment is sane. 89# 90 91AC_DEFUN(AM_SANITY_CHECK, 92[AC_MSG_CHECKING([whether build environment is sane]) 93# Just in case 94sleep 1 95echo timestamp > conftestfile 96# Do `set' in a subshell so we don't clobber the current shell's 97# arguments. Must try -L first in case configure is actually a 98# symlink; some systems play weird games with the mod time of symlinks 99# (eg FreeBSD returns the mod time of the symlink's containing 100# directory). 101if ( 102 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` 103 if test "[$]*" = "X"; then 104 # -L didn't work. 105 set X `ls -t $srcdir/configure conftestfile` 106 fi 107 if test "[$]*" != "X $srcdir/configure conftestfile" \ 108 && test "[$]*" != "X conftestfile $srcdir/configure"; then 109 110 # If neither matched, then we have a broken ls. This can happen 111 # if, for instance, CONFIG_SHELL is bash and it inherits a 112 # broken ls alias from the environment. This has actually 113 # happened. Such a system could not be considered "sane". 114 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 115alias in your environment]) 116 fi 117 118 test "[$]2" = conftestfile 119 ) 120then 121 # Ok. 122 : 123else 124 AC_MSG_ERROR([newly created file is older than distributed files! 125Check your system clock]) 126fi 127rm -f conftest* 128AC_MSG_RESULT(yes)]) 129 130dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY) 131dnl The program must properly implement --version. 132AC_DEFUN(AM_MISSING_PROG, 133[AC_MSG_CHECKING(for working $2) 134# Run test in a subshell; some versions of sh will print an error if 135# an executable is not found, even if stderr is redirected. 136# Redirect stdin to placate older versions of autoconf. Sigh. 137if ($2 --version) < /dev/null > /dev/null 2>&1; then 138 $1=$2 139 AC_MSG_RESULT(found) 140else 141 $1="$3/missing $2" 142 AC_MSG_RESULT(missing) 143fi 144AC_SUBST($1)]) 145 146 147# serial 1 148 149AC_DEFUN(AM_C_PROTOTYPES, 150[AC_REQUIRE([AM_PROG_CC_STDC]) 151AC_REQUIRE([AC_PROG_CPP]) 152AC_MSG_CHECKING([for function prototypes]) 153if test "$am_cv_prog_cc_stdc" != no; then 154 AC_MSG_RESULT(yes) 155 AC_DEFINE(PROTOTYPES,1,[Define if compiler has function prototypes]) 156 U= ANSI2KNR= 157else 158 AC_MSG_RESULT(no) 159 U=_ ANSI2KNR=./ansi2knr 160 # Ensure some checks needed by ansi2knr itself. 161 AC_HEADER_STDC 162 AC_CHECK_HEADERS(string.h) 163fi 164AC_SUBST(U)dnl 165AC_SUBST(ANSI2KNR)dnl 166]) 167 168 169# serial 1 170 171# @defmac AC_PROG_CC_STDC 172# @maindex PROG_CC_STDC 173# @ovindex CC 174# If the C compiler in not in ANSI C mode by default, try to add an option 175# to output variable @code{CC} to make it so. This macro tries various 176# options that select ANSI C on some system or another. It considers the 177# compiler to be in ANSI C mode if it handles function prototypes correctly. 178# 179# If you use this macro, you should check after calling it whether the C 180# compiler has been set to accept ANSI C; if not, the shell variable 181# @code{am_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source 182# code in ANSI C, you can make an un-ANSIfied copy of it by using the 183# program @code{ansi2knr}, which comes with Ghostscript. 184# @end defmac 185 186AC_DEFUN(AM_PROG_CC_STDC, 187[AC_REQUIRE([AC_PROG_CC]) 188AC_BEFORE([$0], [AC_C_INLINE]) 189AC_BEFORE([$0], [AC_C_CONST]) 190dnl Force this before AC_PROG_CPP. Some cpp's, eg on HPUX, require 191dnl a magic option to avoid problems with ANSI preprocessor commands 192dnl like #elif. 193dnl FIXME: can't do this because then AC_AIX won't work due to a 194dnl circular dependency. 195dnl AC_BEFORE([$0], [AC_PROG_CPP]) 196AC_MSG_CHECKING(for ${CC-cc} option to accept ANSI C) 197AC_CACHE_VAL(am_cv_prog_cc_stdc, 198[am_cv_prog_cc_stdc=no 199ac_save_CC="$CC" 200# Don't try gcc -ansi; that turns off useful extensions and 201# breaks some systems' header files. 202# AIX -qlanglvl=ansi 203# Ultrix and OSF/1 -std1 204# HP-UX -Aa -D_HPUX_SOURCE 205# SVR4 -Xc -D__EXTENSIONS__ 206for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 207do 208 CC="$ac_save_CC $ac_arg" 209 AC_TRY_COMPILE( 210[#include <stdarg.h> 211#include <stdio.h> 212#include <sys/types.h> 213#include <sys/stat.h> 214/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 215struct buf { int x; }; 216FILE * (*rcsopen) (struct buf *, struct stat *, int); 217static char *e (p, i) 218 char **p; 219 int i; 220{ 221 return p[i]; 222} 223static char *f (char * (*g) (char **, int), char **p, ...) 224{ 225 char *s; 226 va_list v; 227 va_start (v,p); 228 s = g (p, va_arg (v,int)); 229 va_end (v); 230 return s; 231} 232int test (int i, double x); 233struct s1 {int (*f) (int a);}; 234struct s2 {int (*f) (double a);}; 235int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 236int argc; 237char **argv; 238], [ 239return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 240], 241[am_cv_prog_cc_stdc="$ac_arg"; break]) 242done 243CC="$ac_save_CC" 244]) 245if test -z "$am_cv_prog_cc_stdc"; then 246 AC_MSG_RESULT([none needed]) 247else 248 AC_MSG_RESULT($am_cv_prog_cc_stdc) 249fi 250case "x$am_cv_prog_cc_stdc" in 251 x|xno) ;; 252 *) CC="$CC $am_cv_prog_cc_stdc" ;; 253esac 254]) 255 256