-dnl Revision 1.5 1999/07/27 18:27:37 mdw
-dnl Fix typo in header line for mdw_DECL_ENVIRON.
-dnl
-dnl Revision 1.4 1999/07/26 23:44:32 mdw
-dnl Reorder and tidy documentation.
-dnl
-dnl Revision 1.3 1999/07/17 10:27:44 mdw
-dnl More useful macros added.
-dnl
-dnl Revision 1.2 1999/05/13 22:57:23 mdw
-dnl Change `-ise' to `-ize' throughout.
-dnl
-dnl Revision 1.1.1.1 1999/05/05 19:23:47 mdw
-dnl New import. The old CVS repository was lost in a disk disaster.
-dnl
-
-dnl----- Common files distribution --------------------------- *@--NOTICE--@*
-dnl
-dnl $Id: aclocal.glob,v 1.5 1999/07/27 18:27:37 mdw Exp $
-
-dnl --- *@-AC_PROG_CC_STDC-@* ---
-dnl
-dnl Author: Franc,ois Pinard
-dnl
-dnl Synopsis: AC_PROG_CC_STDC
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: If the C compiler in not in ANSI C mode by default, try to
-dnl add an option to output variable `CC' to make it so. This
-dnl macro tries various options that select ANSI C on some system
-dnl or another. It considers the compiler to be in ANSI C mode
-dnl if it defines `__STDC__' to 1 and handles function prototypes
-dnl correctly.
-dnl
-dnl If you use this macro, you should check after calling it
-dnl whether the C compiler has been set to accept ANSI C; if not,
-dnl the shell variable `ac_cv_prog_cc_stdc' is set to `no'. If
-dnl you wrote your source code in ANSI C, you can make an
-dnl un-ANSIfied copy of it by using the program `ansi2knr', which
-dnl comes with Ghostscript.
-dnl
-dnl (documentation by Franc,ois Pinard)
-
-AC_DEFUN(AM_PROG_CC_STDC,
-[AC_REQUIRE([AC_PROG_CC])
-AC_BEFORE([$0], [AC_C_INLINE])
-AC_BEFORE([$0], [AC_C_CONST])
-AC_MSG_CHECKING(for ${CC-cc} option to accept ANSI C)
-AC_CACHE_VAL(am_cv_prog_cc_stdc,
-[am_cv_prog_cc_stdc=no
-ac_save_CC="$CC"
-# Don't try gcc -ansi; that turns off useful extensions and
-# breaks some systems' header files.
-# AIX -qlanglvl=ansi
-# Ultrix and OSF/1 -std1
-# HP-UX -Aa -D_HPUX_SOURCE
-# SVR4 -Xc -D__EXTENSIONS__
-for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- AC_TRY_COMPILE(
-[#if !defined(__STDC__) || __STDC__ != 1
-choke me
-#endif
-/* DYNIX/ptx V4.1.3 can't compile sys/stat.h with -Xc -D__EXTENSIONS__. */
-#ifdef _SEQUENT_
-# include <sys/types.h>
-# include <sys/stat.h>
-#endif
-], [
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};],
-[am_cv_prog_cc_stdc="$ac_arg"; break])
-done
-CC="$ac_save_CC"
-])
-if test -z "$am_cv_prog_cc_stdc"; then
- AC_MSG_RESULT([none needed])
-else
- AC_MSG_RESULT($am_cv_prog_cc_stdc)
-fi
-case "x$am_cv_prog_cc_stdc" in
- x|xno) ;;
- *) CC="$CC $am_cv_prog_cc_stdc" ;;
-esac
-])
-
-dnl----- AutoMake macros ------------------------------------- *@--IGNORE--@*
-
-dnl --- *@-AM_CONDITIONAL-@* ---
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_CONDITIONAL(NAME, TEST)
-dnl
-dnl Arguments: NAME = name of the conditional
-dnl TEST = a shell list to execute
-dnl
-dnl Use: Allows conditional sections in Makefiles.
-
-AC_DEFUN(AM_CONDITIONAL,
-[AC_SUBST($1_TRUE)
-AC_SUBST($1_FALSE)
-if $2; then
- $1_TRUE=
- $1_FALSE='#'
-else
- $1_TRUE='#'
- $1_FALSE=
-fi])
-
-dnl --- *@-AM_CYGWIN32-@* ---
-dnl
-dnl Author: Cygnus (I guess)
-dnl
-dnl Synopsis: AM_CYGWIN32
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Check to see if we're running under Cygwin32, without using
-dnl AC_CANONICAL_*. If so, set output variable EXEEXT to
-dnl ".exe". Otherwise set it to "".
-
-dnl AM_CYGWIN32()
-dnl You might think we can do this by checking for a cygwin32-specific
-dnl cpp define. We can't, because cross-compilers that target
-dnl cygwin32 don't use the .exe suffix. I don't know why.
-AC_DEFUN(AM_CYGWIN32,
-[AC_CACHE_CHECK(for Cygwin32 environment, am_cv_cygwin32,
-[cat > conftest.$ac_ext << 'EOF'
-int main () {
-/* Nothing. */
-return 0; }
-EOF
-if AC_TRY_EVAL(ac_link) && test -s conftest.exe; then
- am_cv_cygwin32=yes
-else
- am_cv_cygwin32=no
-fi
-rm -f conftest*])
-EXEEXT=
-test "$am_cv_cygwin32" = yes && EXEEXT=.exe
-AC_SUBST(EXEEXT)])
-
-dnl --- *@-AM_WITH_DMALLOC-@* ---
-dnl
-dnl Author: Franc,ois Pinard
-dnl
-dnl Synopsis: AM_WITH_DMALLOC
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Links with `-dmalloc' if told to by the user.
-
-## ----------------------------------- ##
-## Check if --with-dmalloc was given. ##
-## From Franc,ois Pinard ##
-## ----------------------------------- ##
-
-# serial 1
-
-AC_DEFUN(AM_WITH_DMALLOC,
-[AC_MSG_CHECKING(if malloc debugging is wanted)
-AC_ARG_WITH(dmalloc,
-[ --with-dmalloc use dmalloc, as in
- ftp://ftp.letters.com/src/dmalloc/dmalloc.tar.gz],
-[if test "$withval" = yes; then
- AC_MSG_RESULT(yes)
- AC_DEFINE(WITH_DMALLOC)
- LIBS="$LIBS -ldmalloc"
- LDFLAGS="$LDFLAGS -g"
-else
- AC_MSG_RESULT(no)
-fi], [AC_MSG_RESULT(no)])
-])
-
-dnl --- *@-AM_FUNC_ERROR_AT_LINE-@* ---
-dnl
-dnl Author: Jim Meyering
-dnl
-dnl Synopsis: AM_FUNC_ERROR_AT_LINE
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Use this if you use the GNU error.[ch].
-
-dnl FIXME: Migrate into libit
-
-AC_DEFUN(AM_FUNC_ERROR_AT_LINE,
-[AC_CACHE_CHECK([for error_at_line], am_cv_lib_error_at_line,
- [AC_TRY_LINK([],[error_at_line(0, 0, "", 0, "");],
- am_cv_lib_error_at_line=yes,
- am_cv_lib_error_at_line=no)])
- if test $am_cv_lib_error_at_line = no; then
- LIBOBJS="$LIBOBJS error.o"
- fi
- AC_SUBST(LIBOBJS)dnl
-])
-
-dnl --- *@-AM_INIT_GUILE_MODULE-@* ---
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_INIT_GUILE_MODULE(MODNAME)
-dnl
-dnl Arguments: MODNAME = value to initialize `module' variable with
-dnl
-dnl Use: This macro will automatically get the guile version from the
-dnl top-level srcdir, and will initialize automake. It also
-dnl defines the `module' variable.
-
-AC_DEFUN([AM_INIT_GUILE_MODULE],[
-. $srcdir/../GUILE-VERSION
-AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
-AC_CONFIG_AUX_DIR(..)
-module=[$1]
-AC_SUBST(module)])
-
-dnl --- *@-AM_CONFIG_HEADER-@* ---
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_CONFIG_HEADER(HEADER ...)
-dnl
-dnl Arguments: HEADER = a header spec, as for AC_CONFIG_HEADER
-dnl
-dnl Use: Like AC_CONFIG_HEADER, but automatically create stamp file.
-
-AC_DEFUN(AM_CONFIG_HEADER,
-[AC_PREREQ([2.12])
-AC_CONFIG_HEADER([$1])
-dnl When config.status generates a header, we must update the stamp-h file.
-dnl This file resides in the same directory as the config header
-dnl that is generated. We must strip everything past the first ":",
-dnl and everything past the last "/".
-AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
-ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
-<<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/
-\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
-<<am_indx=1
-for am_file in <<$1>>; do
- case " <<$>>CONFIG_HEADERS " in
- *" <<$>>am_file "*<<)>>
- echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
- ;;
- esac
- am_indx=`expr "<<$>>am_indx" + 1`
-done<<>>dnl>>)
-changequote([,]))])
-
-dnl --- *@-AM_INIT_AUTOMAKE-@*
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
-dnl
-dnl Arguments: PACKAGE = package name
-dnl VERSION = version number
-dnl NO-DEFINE = if set, don't define package and version number
-dnl
-dnl Use: Do all the work for Automake. This macro actually does too
-dnl much -- some checks are only needed if your package does
-dnl certain things. But this isn't really a big deal.
-
-# serial 1
-
-AC_DEFUN(AM_INIT_AUTOMAKE,
-[AC_REQUIRE([AM_PROG_INSTALL])
-PACKAGE=[$1]
-AC_SUBST(PACKAGE)
-VERSION=[$2]
-AC_SUBST(VERSION)
-dnl test to see if srcdir already configured
-if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
- AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
-fi
-ifelse([$3],,
-AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
-AC_DEFINE_UNQUOTED(VERSION, "$VERSION"))
-AM_SANITY_CHECK
-AC_ARG_PROGRAM
-dnl FIXME This is truly gross.
-missing_dir=`cd $ac_aux_dir && pwd`
-AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
-AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
-AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
-AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
-AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
-AC_PROG_MAKE_SET])
-
-dnl --- *@-AM_PROG_INSTALL-@* ---
-dnl
-dnl Author: Franc,ois Pinard
-dnl
-dnl Synopsis: AM_PROG_INSTALL
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Calls `AC_PROG_INSTALL' to find an installer. Then it sets
-dnl `INSTALL_SCRIPT' to a suitable value if necessary.
-
-# serial 1
-
-AC_DEFUN(AM_PROG_INSTALL,
-[AC_PROG_INSTALL
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL} -m 755'
-AC_SUBST(INSTALL_SCRIPT)dnl
-])
-
-dnl --- *@-AM_PROG_LEX-@* ---
-dnl
-dnl Author: Alexandre Oliva
-dnl
-dnl Synopsis: AM_PROG_LEX
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Replacement for AC_PROG_LEX and AC_DECL_YYTEXT
-
-dnl AM_PROG_LEX
-dnl Look for flex, lex or missing, then run AC_PROG_LEX and AC_DECL_YYTEXT
-AC_DEFUN(AM_PROG_LEX,
-[missing_dir=ifelse([$1],,`cd $ac_aux_dir && pwd`,$1)
-AC_CHECK_PROGS(LEX, flex lex, "$missing_dir/missing flex")
-AC_PROG_LEX
-AC_DECL_YYTEXT])
-
-dnl --- *@-AM_PROG_LIBTOOL-@* ---
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_PROG_LIBTOOL
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Configures `libtool' for the target architecture.
-
-##
-## Configure libtool for the target system.
-##
-# serial 1 AM_PROG_LIBTOOL
-AC_DEFUN(AM_PROG_LIBTOOL,
-[AC_REQUIRE([AC_CANONICAL_HOST])
-AC_REQUIRE([AC_PROG_CC])
-AC_REQUIRE([AC_PROG_RANLIB])
-
-# Always use our own libtool.
-LIBTOOL='$(top_builddir)/libtool'
-AC_SUBST(LIBTOOL)
-
-dnl Allow the --disable-shared flag to stop us from building shared libs.
-AC_ARG_ENABLE(shared,
-[ --enable-shared build shared libraries [default=yes]],
-test "$enableval" = no && libtool_shared=" --disable-shared",
-libtool_shared=)
-
-libtool_flags="$libtool_shared"
-test "$silent" = yes && libtool_flags="$libtool_flags --silent"
-test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
-
-# Actually configure libtool. ac_aux_dir is where install-sh is found.
-CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" LD="$LD" RANLIB="$RANLIB" \
-$ac_aux_dir/ltconfig $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
-|| AC_MSG_ERROR([libtool configure failed])
-])
-
-dnl --- *@-AM_PATH_LISPDIR-@* ---
-dnl
-dnl Author: Ulrich Drepper
-dnl
-dnl Synopsis: AM_PATH_LISPDIR
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Sets the variable `lispdir' to point to a place to install
-dnl Emacs lisp files.
-
-## ------------------------
-## Emacs LISP file handling
-## From Ulrich Drepper
-## ------------------------
-
-# serial 1
-
-AC_DEFUN(AM_PATH_LISPDIR,
- [# If set to t, that means we are running in a shell under Emacs.
- # If you have an Emacs named "t", then use the full path.
- test "$EMACS" = t && EMACS=
- AC_PATH_PROG(EMACS, emacs xemacs, no)
- if test $EMACS != "no"; then
- AC_MSG_CHECKING([where .elc files should go])
- dnl Set default value
- lispdir="\$(datadir)/emacs/site-lisp"
- if test "x$prefix" = "xNONE"; then
- if test -d $ac_default_prefix/share/emacs/site-lisp; then
- lispdir="\$(prefix)/share/emacs/site-lisp"
- else
- if test -d $ac_default_prefix/lib/emacs/site-lisp; then
- lispdir="\$(prefix)/lib/emacs/site-lisp"
- fi
- fi
- else
- if test -d $prefix/share/emacs/site-lisp; then
- lispdir="\$(prefix)/share/emacs/site-lisp"
- else
- if test -d $prefix/lib/emacs/site-lisp; then
- lispdir="\$(prefix)/lib/emacs/site-lisp"
- fi
- fi
- fi
- AC_MSG_RESULT($lispdir)
- fi
- AC_SUBST(lispdir)])
-
-dnl --- *@-AM_MAINTAINTER_MODE-@* ---
-dnl
-dnl Author: Jim Meyering
-dnl
-dnl Synopsis: jm_MAINTAINER_MODE
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Provides an option `--enable-maintainer-mode' which turns
-dnl on rules which might normally be commented out. The
-dnl substitution variable `MAINT' is set to be a comment when
-dnl this option is disabled, which it is by default.
-
-# serial 1
-
-AC_DEFUN(AM_MAINTAINER_MODE,
-[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
- dnl maintainer-mode is disabled by default
- AC_ARG_ENABLE(maintainer-mode,
-[ --enable-maintainer-mode enable make rules and dependencies not useful
- (and sometimes confusing) to the casual installer],
- USE_MAINTAINER_MODE=$enableval,
- USE_MAINTAINER_MODE=no)
- AC_MSG_RESULT($USE_MAINTAINER_MODE)
- if test $USE_MAINTAINER_MODE = yes; then
- MAINT=
- else
- MAINT='#M#'
- fi
- AC_SUBST(MAINT)dnl
-]
-)
-
-dnl --- *@-AM_MISSING_PROG-@* ---
-dnl
-dnl Author: Unknown
-dnl
-dnl Synopsis: AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
-dnl
-dnl Arguments: NAME = variable to set to the file's location
-dnl PROGRAM = name of program to find
-dnl DIRECTORY = directory to look in
-dnl
-dnl Use: Fakes existence of a useful GNU maintainer tool.
-
-AC_DEFUN(AM_MISSING_PROG,
-[AC_MSG_CHECKING(for working $2)
-# Run test in a subshell; some versions of sh will print an error if
-# an executable is not found, even if stderr is redirected.
-# Redirect stdin to placate older versions of autoconf. Sigh.
-if ($2 --version) < /dev/null > /dev/null 2>&1; then
- $1=$2
- AC_MSG_RESULT(found)
-else
- $1="$3/missing $2"
- AC_MSG_RESULT(missing)
-fi
-AC_SUBST($1)])
-
-dnl --- *@-AM_FUNC_MKTIME-@* ---
-dnl
-dnl Author: Jim Meyering
-dnl
-dnl Synopsis: AM_FUNC_MKTIME
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Checks for a working mktime function.
-
-AC_DEFUN(AM_FUNC_MKTIME,
-[AC_REQUIRE([AC_HEADER_TIME])dnl
- AC_CHECK_HEADERS(sys/time.h)
- AC_CACHE_CHECK([for working mktime], am_cv_func_working_mktime,
- [AC_TRY_RUN(
-changequote(<<, >>)dnl
-<</* Test program from Paul Eggert (eggert@twinsun.com)
- and Tony Leneis (tony@plaza.ds.adp.com). */
-#if TIME_WITH_SYS_TIME
-# include <sys/time.h>
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
-#endif
-
-static time_t time_t_max;
-
-/* Values we'll use to set the TZ environment variable. */
-static const char *const tz_strings[] = {
- NULL, "GMT0", "JST-9", "EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
-};
-#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
-
-static void
-mktime_test (now)
- time_t now;
-{
- if (mktime (localtime (&now)) != now)
- exit (1);
- now = time_t_max - now;
- if (mktime (localtime (&now)) != now)
- exit (1);
-}
-
-int
-main ()
-{
- time_t t, delta;
- int i;
-
- for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
- continue;
- time_t_max--;
- delta = time_t_max / 997; /* a suitable prime number */
- for (i = 0; i < N_STRINGS; i++)
- {
- if (tz_strings[i])
- putenv (tz_strings[i]);
-
- for (t = 0; t <= time_t_max - delta; t += delta)
- mktime_test (t);
- mktime_test ((time_t) 60 * 60);
- mktime_test ((time_t) 60 * 60 * 24);
- }
- exit (0);
-}
- >>,
-changequote([, ])dnl
- am_cv_func_working_mktime=yes, am_cv_func_working_mktime=no,
- dnl When crosscompiling, assume mktime is missing or broken.
- am_cv_func_working_mktime=no)
- ])
- if test $am_cv_func_working_mktime = no; then
- LIBOBJS="$LIBOBJS mktime.o"
- fi
-])
-
-dnl --- *@-AM_FUNC_OBSTACK-@* ---
-dnl
-dnl Author: Jim Meyering
-dnl
-dnl Synopsis: AM_FUNC_OBSTACK
-dnl
-dnl Arguments: ---
-dnl
-dnl Use: Checks for GNU obstacks.
-
-AC_DEFUN(AM_FUNC_OBSTACK,
-[AC_CACHE_CHECK([for obstacks], am_cv_func_obstack,
- [AC_TRY_LINK([#include "obstack.h"],
- [struct obstack *mem;obstack_free(mem,(char *) 0)],
- am_cv_func_obstack=yes,
- am_cv_func_obstack=no)])
- if test $am_cv_func_obstack = yes; then
- AC_DEFINE(HAVE_OBSTACK)
- else
- LIBOBJS="$LIBOBJS obstack.o"
- fi
-])
-
-dnl --- *@-AC_C_PROTOTYPES-@* ---
-dnl
-dnl Author: Franc,ois Pinard
-dnl
-dnl Synopsis: AC_C_PROTOTYPES
-dnl
-dnl Arguments: ---