From fc9567cfeb12d14c1cc9bdb766705080a9452933 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sat, 24 Aug 1996 16:20:52 +0000 Subject: [PATCH] m4 fixes --- ChangeLog | 21 +++++++++++++ Makefile.am | 4 +-- Makefile.in | 21 ++++++++----- THANKS | 1 + TODO | 12 ++++++++ acinstall | 35 ++++++++++++++++++++++ lib/acinstall | 35 ++++++++++++++++++++++ lib/am/Makefile.am | 4 +-- m4/AM_C_PROTOTYPES.m4 | 4 ++- m4/AM_FEATURE_CTYPE.m4 | 10 +++++-- m4/AM_FEATURE_ERRNO.m4 | 3 ++ m4/AM_FEATURE_EXIT.m4 | 3 ++ m4/AM_FUNC_FNMATCH.m4 | 2 ++ m4/AM_FUNC_STRTOD.m4 | 13 ++++---- m4/AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 | 2 ++ m4/AM_INIT_AUTOMAKE.m4 | 4 +++ m4/AM_MAINTAINER_MODE.m4 | 3 ++ m4/AM_PATH_LISPDIR.m4 | 3 ++ m4/AM_PROG_CC_STDC.m4 | 16 +++++----- m4/AM_PROG_INSTALL.m4 | 2 ++ m4/AM_PROG_LIBTOOL.m4 | 4 ++- m4/AM_SYSTEM_HEADER.m4 | 2 ++ m4/AM_SYS_POSIX_TERMIOS.m4 | 2 ++ m4/AM_TYPE_PTRDIFF_T.m4 | 8 +++-- m4/AM_WITH_DMALLOC.m4 | 2 ++ m4/AM_WITH_REGEX.m4 | 31 +++++++++---------- m4/Makefile.am | 3 +- m4/Makefile.in | 31 +++++++++---------- 28 files changed, 220 insertions(+), 61 deletions(-) create mode 100755 acinstall create mode 100755 lib/acinstall diff --git a/ChangeLog b/ChangeLog index 64743d90..ba7105ef 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,24 @@ +Sat Aug 24 09:30:46 1996 Tom Tromey + + * acinstall: New file. + + * m4/AM_INIT_AUTOMAKE.m4: Define PACKAGE and VERSION. + + * m4/AM_WITH_REGEX.m4: New version from François Pinard. + + * m4/AM_TYPE_PTRDIFF_T.m4: Use am_cv, not ac_cv. + * m4/AM_C_PROTOTYPES.m4: Ditto. + * m4/AM_FUNC_STRTOD.m4: Ditto. + * m4/AM_PROG_CC_STDC.m4: Ditto. + * m4/AM_PROG_LIBTOOL.m4: Ditto. + +Fri Aug 23 22:23:50 1996 Tom Tromey + + * m4/Makefile.am (m4datadir): New macro + (m4data_DATA): Renamed. + + * Makefile.am (cvs-dist): Depend on distcheck target. + Mon Aug 19 15:37:32 1996 Tom Tromey * automake.in (initialize_global_constants): [common_files] diff --git a/Makefile.am b/Makefile.am index 7bfaa1e2..2f0e4a92 100644 --- a/Makefile.am +++ b/Makefile.am @@ -22,7 +22,7 @@ ansi2knr.1 aclocal.m4 lisp.am lisp-clean.am ## These must all be executable when installed. pkgdata_SCRIPTS = config.guess config.sub install-sh interlock mdate-sh \ -mkinstalldirs elisp-comp ylwrap +mkinstalldirs elisp-comp ylwrap acinstall # The following requires a fixed version of the Emacs 19.30 etags. ETAGS_ARGS = automake.in aclocal.in --lang=none \ @@ -70,7 +70,7 @@ maintainer-check: automake aclocal # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date. -cvs-dist: maintainer-check +cvs-dist: maintainer-check distcheck @if sed 1q $(srcdir)/NEWS | grep -e "$(VERSION)" > /dev/null; then :; else \ echo "NEWS not updated; not releasing" 1>&2; \ exit 1; \ diff --git a/Makefile.in b/Makefile.in index 7b60ddff..f8a169f4 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated automatically by automake 1.1c from Makefile.am +# Makefile.in generated automatically by automake 1.1d from Makefile.am # Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation @@ -59,7 +59,7 @@ programs-clean.am data-clean.am COPYING INSTALL texinfo.tex ansi2knr.c \ ansi2knr.1 aclocal.m4 lisp.am lisp-clean.am pkgdata_SCRIPTS = config.guess config.sub install-sh interlock mdate-sh \ -mkinstalldirs elisp-comp ylwrap +mkinstalldirs elisp-comp ylwrap acinstall # The following requires a fixed version of the Emacs 19.30 etags. ETAGS_ARGS = automake.in aclocal.in --lang=none \ @@ -73,7 +73,7 @@ SCRIPTS = $(bin_SCRIPTS) $(pkgdata_SCRIPTS) MAKEINFO = makeinfo TEXI2DVI = texi2dvi -INFOS = automake.info automake.info-[0-9] automake.info-[0-9][0-9] +INFOS = automake.info[-0-9]* INFO_DEPS = automake.info DVIS = automake.dvi TEXINFOS = automake.texi @@ -83,8 +83,8 @@ DATA = $(pkgdata_DATA) DIST_COMMON = README AUTHORS COPYING ChangeLog INSTALL Makefile.am \ Makefile.in NEWS README THANKS TODO aclocal.in aclocal.m4 ansi2knr.1 \ ansi2knr.c automake.in config.guess config.sub configure configure.in \ -elisp-comp install-sh mdate-sh mkinstalldirs stamp-vti texinfo.tex \ -version.texi +elisp-comp install-sh interlock mdate-sh mkinstalldirs stamp-vti \ +texinfo.tex version.texi ylwrap PACKAGE = @PACKAGE@ @@ -184,6 +184,13 @@ automake.dvi: automake.texi version.texi .texi.dvi: TEXINPUTS=$(srcdir):$$TEXINPUTS $(TEXI2DVI) $< +.texinfo.info: + cd $(srcdir) \ + && $(MAKEINFO) `echo $< | sed 's,.*/,,'` + +.texinfo.dvi: + TEXINPUTS=$(srcdir):$$TEXINPUTS $(TEXI2DVI) $< + install-info: $(INFO_DEPS) $(mkinstalldirs) $(infodir) for file in $(INFO_DEPS); do \ @@ -445,7 +452,7 @@ maintainer-check: automake aclocal # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date. -cvs-dist: maintainer-check +cvs-dist: maintainer-check distcheck @if sed 1q $(srcdir)/NEWS | grep -e "$(VERSION)" > /dev/null; then :; else \ echo "NEWS not updated; not releasing" 1>&2; \ exit 1; \ @@ -460,7 +467,7 @@ cvs-diff: cvs -f rdiff -c -r $$prevver -r $$thisver $(PACKAGE) \ > $(PACKAGE)-$$prevno-$(VERSION).diff .SUFFIXES: -.SUFFIXES: .texi .info .dvi +.SUFFIXES: .texi .texinfo .info .dvi # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/THANKS b/THANKS index 888c4c5f..44b58291 100644 --- a/THANKS +++ b/THANKS @@ -24,4 +24,5 @@ Markku Rossi Noah Friedman Nyul Laszlo Thomas Morgan +Tom Tromey Ulrich Drepper diff --git a/TODO b/TODO index 3777b379..b0bf9631 100644 --- a/TODO +++ b/TODO @@ -4,6 +4,11 @@ Priorities for release: !! Must fix require_file stuff. It is really gross, and I don't understand it any more. +!! remove autosystem-specific macros +!! should write autoconf-style doc entries for each m4 macro + +should put inverse of @MAINT@ before `.PHONY: configure' + * some options must be turned off when --gnu or higher eg no-installinfo @@ -56,6 +61,13 @@ files, which means rewriting so that the Makefile.am contents aren't copied into the output immediately. This feature is probably required to fully support libtool ("grody compilation issue") +Henrik Frystyk Nielsen says: +Henrik> 4) Flags like --include-deps are lost when you make changes to +Henrik> Makefile.am files and automake is run automatically. It would +Henrik> be nice to keep these flags as I now have to redo everything +Henrik> manually. +... what about other options here too? + Think about: maybe "make check" should just bomb if error occurs? Then user must use "make -k check". This is probably more natural. diff --git a/acinstall b/acinstall new file mode 100755 index 00000000..e77fdf5a --- /dev/null +++ b/acinstall @@ -0,0 +1,35 @@ +#! /bin/sh + +# Install an aclocal-style M4 file. A script is needed to do this +# because we want to do serial-number checking; newer versions of +# macro files should always be preferred. + +# Usage: +# acinstall file directory installprogram [install-args]... + +file="$1" +dir="$2" +shift +shift + +localserial="`grep '^# serial' $file | sed -e 's/^# serial //g'`" +if test -z "$localserial"; then + echo "acinstall: no serial number in $file" 1>&2 + exit 1 +fi + +# Maybe if the installed file has no serial number we should just +# assume it is ancient. +instserial="`grep '^# serial' $dir/$file | sed -e 's/^# serial //g'`" +if test -z "$instserial"; then + echo "acinstall: no serial number in $dir/$file" 1>&2 + exit 1 +fi + +if test $localserial -lt $instserial; then + # Installed file is newer. + exit 0 +fi + +# Install the file. +$* $file $dir/$file diff --git a/lib/acinstall b/lib/acinstall new file mode 100755 index 00000000..e77fdf5a --- /dev/null +++ b/lib/acinstall @@ -0,0 +1,35 @@ +#! /bin/sh + +# Install an aclocal-style M4 file. A script is needed to do this +# because we want to do serial-number checking; newer versions of +# macro files should always be preferred. + +# Usage: +# acinstall file directory installprogram [install-args]... + +file="$1" +dir="$2" +shift +shift + +localserial="`grep '^# serial' $file | sed -e 's/^# serial //g'`" +if test -z "$localserial"; then + echo "acinstall: no serial number in $file" 1>&2 + exit 1 +fi + +# Maybe if the installed file has no serial number we should just +# assume it is ancient. +instserial="`grep '^# serial' $dir/$file | sed -e 's/^# serial //g'`" +if test -z "$instserial"; then + echo "acinstall: no serial number in $dir/$file" 1>&2 + exit 1 +fi + +if test $localserial -lt $instserial; then + # Installed file is newer. + exit 0 +fi + +# Install the file. +$* $file $dir/$file diff --git a/lib/am/Makefile.am b/lib/am/Makefile.am index 7bfaa1e2..2f0e4a92 100644 --- a/lib/am/Makefile.am +++ b/lib/am/Makefile.am @@ -22,7 +22,7 @@ ansi2knr.1 aclocal.m4 lisp.am lisp-clean.am ## These must all be executable when installed. pkgdata_SCRIPTS = config.guess config.sub install-sh interlock mdate-sh \ -mkinstalldirs elisp-comp ylwrap +mkinstalldirs elisp-comp ylwrap acinstall # The following requires a fixed version of the Emacs 19.30 etags. ETAGS_ARGS = automake.in aclocal.in --lang=none \ @@ -70,7 +70,7 @@ maintainer-check: automake aclocal # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date. -cvs-dist: maintainer-check +cvs-dist: maintainer-check distcheck @if sed 1q $(srcdir)/NEWS | grep -e "$(VERSION)" > /dev/null; then :; else \ echo "NEWS not updated; not releasing" 1>&2; \ exit 1; \ diff --git a/m4/AM_C_PROTOTYPES.m4 b/m4/AM_C_PROTOTYPES.m4 index 549b9743..5c82294e 100644 --- a/m4/AM_C_PROTOTYPES.m4 +++ b/m4/AM_C_PROTOTYPES.m4 @@ -3,11 +3,13 @@ ## From Franc,ois Pinard ## ## ------------------------------- ## +# serial 1 + AC_DEFUN(AM_C_PROTOTYPES, [AC_REQUIRE([AM_PROG_CC_STDC]) AC_BEFORE([$0], [AC_C_INLINE]) AC_MSG_CHECKING([for function prototypes]) -if test "$ac_cv_prog_cc_stdc" != no; then +if test "$am_cv_prog_cc_stdc" != no; then AC_MSG_RESULT(yes) AC_DEFINE(PROTOTYPES) U= ANSI2KNR= diff --git a/m4/AM_FEATURE_CTYPE.m4 b/m4/AM_FEATURE_CTYPE.m4 index a5cb4ff2..9ca09ff5 100644 --- a/m4/AM_FEATURE_CTYPE.m4 +++ b/m4/AM_FEATURE_CTYPE.m4 @@ -1,5 +1,11 @@ -dnl Use this in conjunction with autosystem to get working ctype-style -dnl macros. +## -------------------------- ## +## Use in conjunction with ## +## autosystem to get working ## +## ctype-style macros ## +## Tom Tromey ## +## -------------------------- ## + +# serial 1 AC_DEFUN([AM_FEATURE_CTYPE], AC_REQUIRE([AC_HEADER_STDC])) diff --git a/m4/AM_FEATURE_ERRNO.m4 b/m4/AM_FEATURE_ERRNO.m4 index 240ac5ca..47158375 100644 --- a/m4/AM_FEATURE_ERRNO.m4 +++ b/m4/AM_FEATURE_ERRNO.m4 @@ -1,4 +1,7 @@ dnl Use this in conjunction with autosystem to get `errno'. dnl Doesn't actually require any definition; it just assumes that dnl exists. + +# serial 1 + AC_DEFUN([AM_FEATURE_ERRNO]) diff --git a/m4/AM_FEATURE_EXIT.m4 b/m4/AM_FEATURE_EXIT.m4 index f2faf7e7..3bd37a90 100644 --- a/m4/AM_FEATURE_EXIT.m4 +++ b/m4/AM_FEATURE_EXIT.m4 @@ -2,4 +2,7 @@ dnl Use this in conjunction with autosystem to get `exit', dnl EXIT_SUCCESS, and EXIT_FAILURE. dnl Doesn't actually require any definition; it just assumes that dnl exists. + +# serial 1 + AC_DEFUN([AM_FEATURE_EXIT]) diff --git a/m4/AM_FUNC_FNMATCH.m4 b/m4/AM_FUNC_FNMATCH.m4 index d280b90e..2ab15f2d 100644 --- a/m4/AM_FUNC_FNMATCH.m4 +++ b/m4/AM_FUNC_FNMATCH.m4 @@ -2,6 +2,8 @@ ## Check for a working fnmatch ## ## --------------------------- ## +# serial 1 + # @defmac AC_FUNC_FNMATCH # @maindex FUNC_FNMATCH # @ovindex LIBOBJS diff --git a/m4/AM_FUNC_STRTOD.m4 b/m4/AM_FUNC_STRTOD.m4 index af74bdc6..681ac39e 100644 --- a/m4/AM_FUNC_STRTOD.m4 +++ b/m4/AM_FUNC_STRTOD.m4 @@ -1,6 +1,9 @@ dnl From Jim Meyering. + +# serial 1 + AC_DEFUN(AM_FUNC_STRTOD, -[AC_CACHE_CHECK(for working strtod, ac_cv_func_strtod, +[AC_CACHE_CHECK(for working strtod, am_cv_func_strtod, [AC_TRY_RUN([ double strtod (); int @@ -27,12 +30,12 @@ main() } exit (0); } -], ac_cv_func_strtod=yes, ac_cv_func_strtod=no, ac_cv_func_strtod=no)]) -test $ac_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o" +], am_cv_func_strtod=yes, am_cv_func_strtod=no, am_cv_func_strtod=no)]) +test $am_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o" AC_SUBST(LIBOBJS)dnl -if test $ac_cv_func_strtod = no; then +if test $am_cv_func_strtod = no; then AC_CHECK_FUNCS(pow) - if test $ac_cv_func_pow = no; then + if test $am_cv_func_pow = no; then AC_CHECK_LIB(m, pow) fi fi diff --git a/m4/AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 b/m4/AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 index 6d5f837b..163e512b 100644 --- a/m4/AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 +++ b/m4/AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 @@ -1,5 +1,7 @@ dnl From Jim Meyering. +# serial 1 + AC_DEFUN(AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL, [AC_REQUIRE([AM_SYS_POSIX_TERMIOS]) AC_CACHE_CHECK([whether use of TIOCGWINSZ requires sys/ioctl.h], diff --git a/m4/AM_INIT_AUTOMAKE.m4 b/m4/AM_INIT_AUTOMAKE.m4 index 340a57cb..4825742f 100644 --- a/m4/AM_INIT_AUTOMAKE.m4 +++ b/m4/AM_INIT_AUTOMAKE.m4 @@ -2,6 +2,8 @@ # some checks are only needed if your package does certain things. # But this isn't really a big deal. +# serial 1 + dnl Usage: dnl AM_INIT_AUTOMAKE(package,version) @@ -9,7 +11,9 @@ AC_DEFUN(AM_INIT_AUTOMAKE, [AC_REQUIRE([AM_PROG_INSTALL]) PACKAGE=[$1] AC_SUBST(PACKAGE) +AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE") VERSION=[$2] AC_SUBST(VERSION) +AC_DEFINE_UNQUOTED(VERSION, "$VERSION") AC_ARG_PROGRAM AC_PROG_MAKE_SET]) diff --git a/m4/AM_MAINTAINER_MODE.m4 b/m4/AM_MAINTAINER_MODE.m4 index 4a9f1919..5d9a7658 100644 --- a/m4/AM_MAINTAINER_MODE.m4 +++ b/m4/AM_MAINTAINER_MODE.m4 @@ -1,5 +1,8 @@ # Add --enable-maintainer-mode option to configure. # From Jim Meyering + +# 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 diff --git a/m4/AM_PATH_LISPDIR.m4 b/m4/AM_PATH_LISPDIR.m4 index 4fbe0985..d223cb84 100644 --- a/m4/AM_PATH_LISPDIR.m4 +++ b/m4/AM_PATH_LISPDIR.m4 @@ -2,6 +2,9 @@ ## Emacs LISP file handling ## From Ulrich Drepper ## ------------------------ + +# serial 1 + AC_DEFUN(AM_PATH_LISPDIR, [AC_PATH_PROG(EMACS, emacs xemacs, no) if test $EMACS != "no"; then diff --git a/m4/AM_PROG_CC_STDC.m4 b/m4/AM_PROG_CC_STDC.m4 index 7ef64025..70c76912 100644 --- a/m4/AM_PROG_CC_STDC.m4 +++ b/m4/AM_PROG_CC_STDC.m4 @@ -3,6 +3,8 @@ ## From Franc,ois Pinard ## ## ----------------------------------------- ## +# serial 1 + # @defmac AC_PROG_CC_STDC # @maindex PROG_CC_STDC # @ovindex CC @@ -14,7 +16,7 @@ # # If you use this macro, you should check after calling it whether the C # compiler has been set to accept ANSI C; if not, the shell variable -# @code{ac_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source +# @code{am_cv_prog_cc_stdc} is set to @samp{no}. If you wrote your source # code in ANSI C, you can make an un-ANSIfied copy of it by using the # program @code{ansi2knr}, which comes with Ghostscript. # @end defmac @@ -22,8 +24,8 @@ AC_DEFUN(AM_PROG_CC_STDC, [AC_REQUIRE([AC_PROG_CC]) AC_MSG_CHECKING(for ${CC-cc} option to accept ANSI C) -AC_CACHE_VAL(ac_cv_prog_cc_stdc, -[ac_cv_prog_cc_stdc=no +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. @@ -44,13 +46,13 @@ choke me int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);};], -[ac_cv_prog_cc_stdc="$ac_arg"; break]) +[am_cv_prog_cc_stdc="$ac_arg"; break]) done CC="$ac_save_CC" ]) -AC_MSG_RESULT($ac_cv_prog_cc_stdc) -case "x$ac_cv_prog_cc_stdc" in +AC_MSG_RESULT($am_cv_prog_cc_stdc) +case "x$am_cv_prog_cc_stdc" in x|xno) ;; - *) CC="$CC $ac_cv_prog_cc_stdc" ;; + *) CC="$CC $am_cv_prog_cc_stdc" ;; esac ]) diff --git a/m4/AM_PROG_INSTALL.m4 b/m4/AM_PROG_INSTALL.m4 index b82b47eb..75831fac 100644 --- a/m4/AM_PROG_INSTALL.m4 +++ b/m4/AM_PROG_INSTALL.m4 @@ -4,6 +4,8 @@ ## From Franc,ois Pinard ## ## --------------------------------------------------------- ## +# serial 1 + AC_DEFUN(AM_PROG_INSTALL, [AC_REQUIRE([AC_PROG_INSTALL]) test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL} -m 755' diff --git a/m4/AM_PROG_LIBTOOL.m4 b/m4/AM_PROG_LIBTOOL.m4 index d52db6f8..92146415 100644 --- a/m4/AM_PROG_LIBTOOL.m4 +++ b/m4/AM_PROG_LIBTOOL.m4 @@ -3,6 +3,8 @@ ## From Gord Matzigkeit ## ## --------------------------------------------------------- ## +# serial 1 + AC_DEFUN(AM_PROG_LIBTOOL, [AC_REQUIRE([AC_CANONICAL_HOST]) AC_REQUIRE([AC_PROG_CC]) @@ -85,6 +87,6 @@ esac # Holy mackerel, what a command line! CC="$CC" LD="$LD" RANLIB="$RANLIB" OBJTYPES="$OBJTYPES" \ $srcdir/libtool --host="$host" --libdir="$am_prog_libtool_libdir" --no-validate-host \ ---with-gcc="$ac_cv_prog_gcc" $am_prog_libtool_flags \ +--with-gcc="$am_cv_prog_gcc" $am_prog_libtool_flags \ configure || AC_MSG_ERROR([libtool configure failed]) ]) diff --git a/m4/AM_SYSTEM_HEADER.m4 b/m4/AM_SYSTEM_HEADER.m4 index c4f20a5d..3f6d584d 100644 --- a/m4/AM_SYSTEM_HEADER.m4 +++ b/m4/AM_SYSTEM_HEADER.m4 @@ -1 +1,3 @@ +# serial 1 + AC_DEFUN([AM_SYSTEM_HEADER]) diff --git a/m4/AM_SYS_POSIX_TERMIOS.m4 b/m4/AM_SYS_POSIX_TERMIOS.m4 index 2eb3bd97..1eb31d1e 100644 --- a/m4/AM_SYS_POSIX_TERMIOS.m4 +++ b/m4/AM_SYS_POSIX_TERMIOS.m4 @@ -1,5 +1,7 @@ dnl From Jim Meyering. +# serial 1 + AC_DEFUN(AM_SYS_POSIX_TERMIOS, [AC_CACHE_CHECK([POSIX termios], am_cv_sys_posix_termios, [AC_TRY_LINK([#include diff --git a/m4/AM_TYPE_PTRDIFF_T.m4 b/m4/AM_TYPE_PTRDIFF_T.m4 index ab633a1e..85bf4ace 100644 --- a/m4/AM_TYPE_PTRDIFF_T.m4 +++ b/m4/AM_TYPE_PTRDIFF_T.m4 @@ -1,10 +1,12 @@ # From Ulrich Drepper. +# serial 1 + AC_DEFUN(AM_TYPE_PTRDIFF_T, - [AC_CACHE_CHECK([for ptrdiff_t], ac_cv_type_ptrdiff_t, + [AC_CACHE_CHECK([for ptrdiff_t], am_cv_type_ptrdiff_t, [AC_TRY_COMPILE([#include ], [ptrdiff_t p], - ac_cv_type_ptrdiff_t=yes, ac_cv_type_ptrdiff_t=no)]) - if test $ac_cv_type_ptrdiff_t = yes; then + am_cv_type_ptrdiff_t=yes, am_cv_type_ptrdiff_t=no)]) + if test $am_cv_type_ptrdiff_t = yes; then AC_DEFINE(HAVE_PTRDIFF_T) fi ]) diff --git a/m4/AM_WITH_DMALLOC.m4 b/m4/AM_WITH_DMALLOC.m4 index bfd064a5..365ef803 100644 --- a/m4/AM_WITH_DMALLOC.m4 +++ b/m4/AM_WITH_DMALLOC.m4 @@ -3,6 +3,8 @@ ## From Franc,ois Pinard ## ## ----------------------------------- ## +# serial 1 + AC_DEFUN(AM_WITH_DMALLOC, [AC_MSG_CHECKING(if malloc debugging is wanted) AC_ARG_WITH(dmalloc, diff --git a/m4/AM_WITH_REGEX.m4 b/m4/AM_WITH_REGEX.m4 index e1249e52..3d15c75f 100644 --- a/m4/AM_WITH_REGEX.m4 +++ b/m4/AM_WITH_REGEX.m4 @@ -1,29 +1,30 @@ ## --------------------------------- ## ## Check if --with-regex was given. ## -## From Franc,ois Pinard ## ## --------------------------------- ## -# The idea is to distribute rx.[hc] and regex.[hc] together, for -# a while. The WITH_REGEX symbol (which should also be documented -# in acconfig.h) is used to decide which of regex.h or rx.h should -# be included in the application. If `./configure --with-regex' is -# given, the package will use the older regex. Else, a check is -# made to see if rx is already installed, as with newer Linux'es. +# serial 1 + +# The idea is to distribute rx.[hc] and regex.[hc] together, for a while. +# The WITH_REGEX symbol (which should also be documented in acconfig.h) +# is used to decide which of regex.h or rx.h should be included in the +# application. If `./configure --with-regex' is given (the default), the +# package will use gawk's regex. If `./configure --without-regex', a +# check is made to see if rx is already installed, as with newer Linux'es. # If not found, the package will use the rx from the distribution. -# If found, the package will use the system's rx which, on Linux -# at least, will result in a smaller executable file. +# If found, the package will use the system's rx which, on Linux at least, +# will result in a smaller executable file. AC_DEFUN(AM_WITH_REGEX, -[AC_MSG_CHECKING(which of rx or regex is wanted) +[AC_MSG_CHECKING(which of GNU rx or gawk's regex is wanted) AC_ARG_WITH(regex, -[ --with-regex use older regex in lieu of GNU rx for matching], -[if test "$withval" = yes; then - ac_with_regex=1 +[ --without-regex use GNU rx in lieu of gawk's regex for matching], +[test "$withval" = yes && am_with_regex=1], +[am_with_regex=1]) +if test -n "$am_with_regex"; then AC_MSG_RESULT(regex) AC_DEFINE(WITH_REGEX) LIBOBJS="$LIBOBJS regex.o" -fi]) -if test -z "$ac_with_regex"; then +else AC_MSG_RESULT(rx) AC_CHECK_FUNC(re_rx_search, , [LIBOBJS="$LIBOBJS rx.o"]) fi diff --git a/m4/Makefile.am b/m4/Makefile.am index 47b1e845..f54074b9 100644 --- a/m4/Makefile.am +++ b/m4/Makefile.am @@ -3,7 +3,8 @@ AUTOMAKE_OPTIONS = gnits MAINT_CHARSET = latin1 -pkgdata_DATA = AM_C_PROTOTYPES.m4 AM_FEATURE_CTYPE.m4 \ +m4datadir = $(datadir)/aclocal +m4data_DATA = AM_C_PROTOTYPES.m4 AM_FEATURE_CTYPE.m4 \ AM_FEATURE_ERRNO.m4 AM_FEATURE_EXIT.m4 AM_FUNC_FNMATCH.m4 \ AM_MAINTAINER_MODE.m4 AM_PATH_LISPDIR.m4 AM_PROG_CC_STDC.m4 \ AM_PROG_INSTALL.m4 AM_PROG_LIBTOOL.m4 AM_SYSTEM_HEADER.m4 \ diff --git a/m4/Makefile.in b/m4/Makefile.in index 8b4be72a..9fb1ce95 100644 --- a/m4/Makefile.in +++ b/m4/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated automatically by automake 1.1c from Makefile.am +# Makefile.in generated automatically by automake 1.1d from Makefile.am # Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation @@ -41,7 +41,8 @@ transform = @program_transform_name@ AUTOMAKE_OPTIONS = gnits MAINT_CHARSET = latin1 -pkgdata_DATA = AM_C_PROTOTYPES.m4 AM_FEATURE_CTYPE.m4 \ +m4datadir = $(datadir)/aclocal +m4data_DATA = AM_C_PROTOTYPES.m4 AM_FEATURE_CTYPE.m4 \ AM_FEATURE_ERRNO.m4 AM_FEATURE_EXIT.m4 AM_FUNC_FNMATCH.m4 \ AM_MAINTAINER_MODE.m4 AM_PATH_LISPDIR.m4 AM_PROG_CC_STDC.m4 \ AM_PROG_INSTALL.m4 AM_PROG_LIBTOOL.m4 AM_SYSTEM_HEADER.m4 \ @@ -51,7 +52,7 @@ AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL.m4 \ AM_SYS_POSIX_TERMIOS.m4 mkinstalldirs = $(top_srcdir)/mkinstalldirs CONFIG_CLEAN_FILES = -DATA = $(pkgdata_DATA) +DATA = $(m4data_DATA) DIST_COMMON = Makefile.am Makefile.in @@ -74,19 +75,19 @@ $(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in Makefile: $(top_builddir)/config.status Makefile.in cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status -install-pkgdataDATA: $(pkgdata_DATA) - $(mkinstalldirs) $(pkgdatadir) - list="$(pkgdata_DATA)"; for p in $$list; do \ +install-m4dataDATA: $(m4data_DATA) + $(mkinstalldirs) $(m4datadir) + list="$(m4data_DATA)"; for p in $$list; do \ if test -f $(srcdir)/$$p; then \ - $(INSTALL_DATA) $(srcdir)/$$p $(pkgdatadir)/$$p; \ + $(INSTALL_DATA) $(srcdir)/$$p $(m4datadir)/$$p; \ else if test -f $$p; then \ - $(INSTALL_DATA) $$p $(pkgdatadir)/$$p; \ + $(INSTALL_DATA) $$p $(m4datadir)/$$p; \ fi; fi; \ done -uninstall-pkgdataDATA: - list="$(pkgdata_DATA)"; for p in $$list; do \ - rm -f $(pkgdatadir)/$$p; \ +uninstall-m4dataDATA: + list="$(m4data_DATA)"; for p in $$list; do \ + rm -f $(m4datadir)/$$p; \ done tags: TAGS TAGS: @@ -111,19 +112,19 @@ installcheck: install-exec: -install-data: install-pkgdataDATA +install-data: install-m4dataDATA install: install-exec install-data all @: -uninstall: uninstall-pkgdataDATA +uninstall: uninstall-m4dataDATA all: $(DATA) Makefile install-strip: $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install installdirs: - $(mkinstalldirs) $(pkgdatadir) + $(mkinstalldirs) $(m4datadir) mostlyclean-generic: @@ -151,7 +152,7 @@ maintainer-clean: maintainer-clean-generic distclean @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." -.PHONY: default uninstall-pkgdataDATA install-pkgdataDATA tags distdir \ +.PHONY: default uninstall-m4dataDATA install-m4dataDATA tags distdir \ info dvi check installcheck install-exec install-data install uninstall \ all installdirs mostlyclean-generic distclean-generic clean-generic \ maintainer-clean-generic clean mostlyclean distclean maintainer-clean -- 2.43.5