Arg, sorry, I sent an incomplete patch, forget it.
Akim
Index: tests/Makefile.am
===================================================================
RCS file: /cvs/autoconf/tests/Makefile.am,v
retrieving revision 1.16
diff -u -r1.16 Makefile.am
--- tests/Makefile.am 2000/03/08 16:12:10 1.16
+++ tests/Makefile.am 2000/03/10 13:39:47
@@ -40,7 +40,7 @@
-# EGREP_EXCLUDE
+# FILTER_MACROS
# -------------
# The test `syntax.m4' tries to run all the macros of Autoconf to check
# for syntax problems, etc. Not all the macros can be run without argument,
@@ -63,25 +63,25 @@
# Used in many places.
# - _AC_
# Internal macros are used elsewhere.
-EGREP_EXCLUDE = egrep -v \
- -e '^AC_ARG_VAR$$' \
- -e '^AC_CHECK_(DECL|FILE|FUNC|HEADER|MEMBER|PROG|SIZEOF|TYPE)S?$$' \
- -e '^AC_CONFIG' \
- -e '^AC_INIT' \
- -e '^AC_LINKER_OPTION$$' \
- -e '^AC_LINK_FILES$$' \
- -e '^AC_LIST_MEMBER_OF$$' \
- -e '^AC_PATH_(TOOL|PROG)S?$$' \
- -e '^AC_PROG_(CC|CXX|F77)_(GNU|WORKS)$$' \
- -e '^AC_REPLACE_FUNCS$$' \
- -e '^AC_SEARCH_LIBS$$' \
- -e '^AC_TRY' \
- -e '_AC_'
+FILTER_MACROS = egrep -v -e \
+`echo '^AC_ARG_VAR$$\
+^AC_CHECK_(DECL|FILE|FUNC|HEADER|MEMBER|PROG|SIZEOF|TYPE)S?$$\
+^AC_CONFIG\
+^AC_INIT\
+^AC_LINKER_OPTION$$\
+^AC_LINK_FILES$$\
+^AC_LIST_MEMBER_OF$$\
+^AC_PATH_(TOOL|PROG)S?$$\
+^AC_PROG_(CC|CXX|F77)_(GNU|WORKS)$$\
+^AC_REPLACE_FUNCS$$\
+^AC_SEARCH_LIBS$$\
+^AC_TRY\
+_AC_' | tr ' ' '|'`
macros.m4: $(top_srcdir)/acgeneral.m4 $(top_srcdir)/acspecific.m4
$(srcdir)/Makefile.am
cat $(top_srcdir)/acgeneral.m4 $(top_srcdir)/acspecific.m4 | \
sed -ne 's/^A[CU]_DEFUN(\[*\([a-zA-Z0-9_]*\).*$$/\1/p' | \
- sort | uniq | $(EGREP_EXCLUDE) >defuns
+ sort | uniq | $(FILTER_MACROS) >defuns
# Get the list of macros that are required: there is little interest
# in testing them since they will be run but the guy who requires
# them.
Index: tests/actest.m4
===================================================================
RCS file: /cvs/autoconf/tests/actest.m4,v
retrieving revision 1.9
diff -u -r1.9 actest.m4
--- tests/actest.m4 2000/03/01 17:01:30 1.9
+++ tests/actest.m4 2000/03/10 13:39:47
@@ -1,7 +1,15 @@
dnl actest.m4 -*- autoconf -*-
dnl Additional Autoconf macros to ease testing.
+# join(SEP, ARG1, ARG2...)
+# ------------------------
+# Produce ARG1SEPARG2...SEPARGn.
+define(join,
+[ifelse([$#], [1], [],
+ [$#], [2], [[[$2]]],
+ [[$2][$1]join([$1], m4_shift(m4_shift($@)))])])
+
# AC_ENV_SAVE(FILE)
# ------------------
# Save the environment, but the variables we are allowed to touch.
@@ -20,20 +28,21 @@
AC_DEFUN(AC_ENV_SAVE,
[(set) 2>&1 |
- egrep -v \
- -e '^ac_' \
- -e '^(CC|CFLAGS|CPP|GCC|CXX|CXXFLAGS|CXXCPP|GXX|F77|FFLAGS|FLIBS|G77)=' \
- -e '^(LIBS|LIBOBJS|LDFLAGS)=' \
- -e '^INSTALL(_(DATA|PROGRAM|SCRIPT))?=' \
- -e '^(CYGWIN|ISC|MINGW32|MINIX|EMXOS2|EXEEXT|OBJEXT)=' \
- -e '^(X_(CFLAGS|(EXTRA_|PRE_)?LIBS)|x_(includes|libraries)|have_x)=' \
- -e '^(host|build|target)(_(alias|cpu|vendor|os))?=' \
- -e '^(cross_compiling)=' \
- -e '^(interpval)=' \
- -e '^(f77_(case|underscore))=' \
- -e '^(ALLOCA|NEED_SETGID|KMEM_GROUP)=' \
- -e '^(AWK|LEX|LEXLIB|LEX_OUTPUT_ROOT|LN_S|M4|RANLIB|SET_MAKE|YACC)=' \
- -e '^(_|OLDPWD|PIPESTATUS|SECONDS)=' |
+ egrep -v -e \
+'join([|],
+ [^ac_],
+ [^(CC|CFLAGS|CPP|GCC|CXX|CXXFLAGS|CXXCPP|GXX|F77|FFLAGS|FLIBS|G77)=],
+ [^(LIBS|LIBOBJS|LDFLAGS)=],
+ [^INSTALL(_(DATA|PROGRAM|SCRIPT))?=],
+ [^(CYGWIN|ISC|MINGW32|MINIX|EMXOS2|EXEEXT|OBJEXT)=],
+ [^(X_(CFLAGS|(EXTRA_|PRE_)?LIBS)|x_(includes|libraries)|have_x)=],
+ [^(host|build|target)(_(alias|cpu|vendor|os))?=],
+ [^(cross_compiling)=],
+ [^(interpval)=],
+ [^(f77_(case|underscore))=],
+ [^(ALLOCA|NEED_SETGID|KMEM_GROUP)=],
+ [^(AWK|LEX|LEXLIB|LEX_OUTPUT_ROOT|LN_S|M4|RANLIB|SET_MAKE|YACC)=],
+ [^(_|OLDPWD|PIPESTATUS|SECONDS)=])' |
# There maybe variables spread on several lines, eg IFS, remove the dead
# lines
fgrep = >$1