Commit Graph

2542 Commits

Author SHA1 Message Date
Paolo Bonzini
cf5862afae Reorganize definition of languages
* lib/autoconf/c.m4 (AC_LANG(C), AC_LANG(C++), AC_LANG(Objective C),
_AC_LANG_ABBREV(C), _AC_LANG_ABBREV(C++), _AC_LANG_ABBREV(Objective C),
_AC_LANG_PREFIX(C), _AC_LANG_PREFIX(C++), _AC_LANG_PREFIX(Objective C)):
Replace definitions with usage of AC_LANG_DEFINE.
(Sections 2b, 2c): Delete.
(Sections 1b, 1c): Move after section 2a.
* lib/autoconf/erlang.m4 (AC_LANG(Erlang), _AC_LANG_ABBREV(Erlang),
_AC_LANG_PREFIX(Erlang), AC_LANG_SOURCE(Erlang)): Replace definitions
with usage of AC_LANG_DEFINE.
(AC_LANG_ERLANG): Define using AU_DEFUN.
* lib/autoconf/fortran.m4 (AC_LANG(Fortran), AC_LANG(Fortran 77),
_AC_LANG_ABBREV(Fortran), _AC_LANG_ABBREV(Fortran 77),
_AC_LANG_PREFIX(Fortran), _AC_LANG_PREFIX(Fortran 77),
_AC_LANG_SOURCE(Fortran), AC_LANG_SOURCE(Fortran 77)): Replace
definitions with usage of AC_LANG_DEFINE.
* lib/autoconf/lang.m4 (AC_LANG_DEFINE, AC_LANG_SOURCE()): New.
2008-11-03 14:23:55 +01:00
Paolo Bonzini
c0e8d2d8ba Rename _AC_CHECK_HEADER_OLD and _AC_CHECK_HEADER_NEW.
* lib/autoconf/headers.m4 (AC_CHECK_HEADER): Adjust naming.
(_AC_CHECK_HEADER_PREPROC_BODY): New name of _AC_CHECK_HEADER_OLD_BODY.
(_AC_CHECK_HEADER_COMPILE_BODY): New name of _AC_CHECK_HEADER_NEW_BODY.
(_AC_CHECK_HEADER_PREPROC): New name of _AC_CHECK_HEADER_OLD.
(_AC_CHECK_HEADER_COMPILE): New name of _AC_CHECK_HEADER_NEW.
* tests/semantics.at (AC_CHECK_HEADERS_OLD, AC_CHECK_HEADER_NEW):
Give better name.
2008-10-31 17:48:03 +01:00
Eric Blake
9279a87aba Support multiple undiverts and dumpdefs at once.
* lib/m4sugar/m4sugar.m4 (m4_dumpdefs, m4_undivert): Allow extra
arguments.
* doc/autoconf.texi (Redefined M4 Macros) <m4_dumpdef>,
<m4_undivert>: Document argument list change.
* tests/m4sugar.at (m4@&t@_divert_stack, m4@&t@_dumpdef): Test
them.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-31 10:30:31 -06:00
Eric Blake
9f4363abb6 Simplify diversion stack handling.
* lib/m4sugar/m4sugar.m4 (m4_divert_stack): Use fewer macros, and
avoid extra newlines.
(m4_divert_stack_push): Compute location here, rather than caller.
(m4_divert_push): Update caller.
(m4_divert): Likewise, and also adjust current diversion name.
(m4_divert_pop): Simplify rule that diversion stack must never go
empty.
(_m4_require_call): Bypass diversion stack when collecting
required macro text.
(m4_init): Set current diversion without requiring m4_init.
* lib/m4sugar/m4sh.m4 (AS_INIT): Avoid too many pops.
* lib/autotest/general.m4 (AT_INIT): Likewise.
* lib/autoconf/general.m4 (_AC_INIT_DEFAULTS): Schedule wrapped
text to run prior to m4sugar cleanup.
* doc/autoconf.texi (Text processing Macros) <m4_newline>: Mention
optional argument.
(Conditional constructs) <m4_ifvaln, m4_n>: Mention use of dnl.
* NEWS: Undo blurb about m4_divert.
* tests/m4sugar.at (m4@&t@_divert_stack): New test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-31 10:25:24 -06:00
Eric Blake
852082f119 Simplify expansion stack handling.
* lib/m4sugar/m4sugar.m4 (m4_expansion_stack): Use fewer macros;
always output 'top level'.
(_m4_expansion_stack_entry): New macro, to format the string only
when needed.
(m4_expansion_stack_push): Only push a macro name.
(m4_warn, _m4_defun_pro): Update callers.
(m4_expansion_stack_pop, m4_expansion_stack_dump): Delete.
(_m4_defun_epi, m4_fatal): Inline the calls.
* tests/m4sugar.at (m4@&t@_expansion_stack): New test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-31 09:59:56 -06:00
Paolo Bonzini
718151138d Do not check for $LINENO in generated scripts.
* lib/m4sugar/m4sh.m4 (_AS_PREPARE): Do not call _AS_LINENO_PREPARE,
and explain why.
2008-10-30 16:57:45 +01:00
Eric Blake
4f4ffdc6a6 Don't check for non-POSIX extensions in suggested tests.
* lib/m4sugar/m4sh.m4 (_AS_VAR_APPEND_WORKS): Remove suggestion;
we still use += if available, but should not reject shells (like
dash) that don't provide it.
(_AS_DETECT_SUGGESTED): Document a policy for m4sh.
Reported by Paolo Bonzini.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-30 09:50:46 -06:00
Paolo Bonzini
26e664439c Pass CONFIG_SHELL down to generated scripts, and re-export SHELL.
* lib/m4sugar/m4sh.m4 (_AS_DETECT_BETTER_SHELL): If proceeding
with a given CONFIG_SHELL, move it to SHELL.
(AS_INIT_GENERATED): Re-export SHELL.
2008-10-30 15:27:42 +01:00
Eric Blake
a78b497413 Work around Solaris /bin/sh case bug.
* lib/m4sugar/m4sh.m4 (_AS_CASE, _AS_CASE_DEFAULT): Always provide
a non-empty command list.
(AS_CASE): Always guarantee that a case will match.
* doc/autoconf.texi (Limitations of Builtins) <case>: Document the
Solaris bug, and mention AS_CASE.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-30 07:40:59 -06:00
Paolo Bonzini
c55740c463 Require _AS_CR_PREPARE where appropriate and fix ChangeLog.
* lib/m4sugar/m4sh.m4 (_AS_PREPARE): Call _AS_CR_PREPARE.
(AS_PREPARE): Require _AS_CR_PREPARE.
2008-10-30 14:00:02 +01:00
Paolo Bonzini
4298bf09e4 trim down the length of the shell function test
* lib/m4sugar/m4sh.m4 (_AS_SHELL_FN_WORK): Condense.
2008-10-30 10:23:40 +01:00
Paolo Bonzini
c29ca1d13b Avoid walking the entire PATH when looking for a better shell.
* lib/m4sugar/m4sh.m4 (_AS_SHELL_SANITIZE): Test shell characteristics
as the PATH is walked.
2008-10-30 09:52:22 +01:00
Paolo Bonzini
3fb0b95667 Add third argument to _AS_PATH_WALK
* lib/m4sugar/m4sh.m4 (_AS_SHELL_SANITIZE): Do not call _AS_CR_PREPARE.
(_AS_PATH_WALK): Add third optional argument.
2008-10-30 09:51:32 +01:00
Eric Blake
d2dabc34ef Fix LINENO detection to work around bash and pdksh limitations.
* lib/m4sugar/m4sh.m4 (_AS_LINENO_WORKS): Enhance the test, so
that we can choose which of two tests to trust.
(_AS_RUN): Set flag when alternate shell is running.
(_AS_DETECT_EXPAND): New macro.
(_AS_DETECT_BETTER_SHELL): Use it to massage LINENO tests.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 16:06:56 -06:00
Eric Blake
e752d8d90f Mention proper fix for zsh users.
* lib/m4sugar/m4sh.m4 (_AS_DETECT_BETTER_SHELL): Recommend zsh
version known to work.
Suggested by Paolo Bonzini.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 15:47:18 -06:00
Eric Blake
c0af9c5e4e Document current beta-quality status.
* configure.ac: Reflect fact that change to git-version-gen
produces -, but not always a letter, on non-release builds.
* BUGS: Mention known issues.
* lib/m4sugar/m4sh.m4 (_AS_DETECT_BETTER_SHELL): Ask for help in
debugging platforms with deficient shells.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 09:30:23 -06:00
Eric Blake
7abb73425a Alter signature of AS_INIT_GENERATED.
* lib/m4sugar/m4sh.m4 (AS_INIT_GENERATED): Add parameters, and
manage here-doc and chmod in place.  This also allows future
changes for optimizing the child via diversion/m4_wrap magic.
* lib/autoconf/status.m4 (_AC_OUTPUT_CONFIG_STATUS): Update
caller.
* doc/autoconf.texi (Initialization Macros) <AS_INIT_GENERATED>:
Update the documentation.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 06:30:40 -06:00
Eric Blake
c602a5c6d0 Use _m4_stack_reverse in m4_set.
* lib/m4sugar/m4sugar.m4 (_m4_set_contents_1)
(_m4_set_contents_2): Rewrite to share _m4_stack_reverse
implementation.
(m4_set_contents, m4_set_foreach, m4_set_list, m4_set_listc)
(m4_set_map): Adjust callers to new API.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 06:29:38 -06:00
Eric Blake
52773c7b70 Add m4_stack_foreach_sep.
* lib/m4sugar/m4sugar.m4 (m4_stack_foreach_sep)
(m4_stack_foreach_sep_lifo): New macros.
(_m4_stack_reverse): Adjust prototype, to support it.
(m4_copy): Use fewer macros.
* tests/m4sugar.at (m4@&t@_stack_foreach): Rename...
(m4@&t@_stack): ...and add m4_stack_foreach_sep tests.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-29 06:28:37 -06:00
Paolo Bonzini
250422b094 Rewrite handling of diversion and expansion stack.
* NEWS: Document stricter requirement on m4_init.
* lib/m4sugar/m4sugar.m4 (m4_divert_stack): New, replacing
_m4_divert_n_stack.
(_m4_divert_stack_push): New.
(m4_divert): Use _m4_divert_stack_push and replace m4_define with
m4_popdef.
(m4_divert_push): Use _m4_divert_stack_push.
(m4_divert_pop): Use m4_divert_stack instead of _m4_divert_n_stack,
pop _m4_divert_stack instead of m4_divert_stack.
(m4_expansion_stack): New.  Update comment above it.
(m4_expansion_stack_push, m4_expansion_stack_pop): Work on
_m4_expansion_stack instead of m4_expansion_stack.
(m4_expansion_stack_dump): Check presence of _m4_expansion_stack
instead of m4_expansion_stack.  Use m4_expansion_stack's expansion
instead of the definition, and compensate for the trailing newline
in the expansion.
(m4_warn, _m4_defun_pro, _m4_defun_epi): Check presence of
_m4_expansion_stack instead of m4_expansion_stack.
(m4_newline): Expand first argument after the newline.
(m4_init): Use m4_divert_stack instead of _m4_divert_n_stack,
* tests/m4sugar.at (m4_append, m4_text_wrap): Invoke m4_init.
* tests/tools.at (whitespace in file names, the empty token): Likewise.
2008-10-29 08:00:08 +01:00
Eric Blake
63ec266226 Reduce forks while searching for better shell.
* lib/m4sugar/m4sh.m4 (_AS_DETECT_REQUIRED)
(_AS_DETECT_SUGGESTED): No need to provide extra subshell; _AS_RUN
already does the job.
(_AS_DETECT_BETTER_SHELL): Simplify AS_EXIT when not run in a trap
0 context.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-28 21:33:46 -06:00
Eric Blake
11c8919bdb Undo needless efforts to protect $2 in $2_t.
* lib/autoconf/types.m4 (_AC_TYPE_INT_BODY)
(_AC_TYPE_UNSIGNED_INT_BODY): Reduce extra quoting.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-28 20:45:58 -06:00
Ralf Wildenhues
b83aa7ee0d Fix parallel test execution output lossage.
* lib/autotest/general.m4 (_AT_CHECK): Truncate files to hold
standard output and standard error before the test, use append
mode for writing.
* THANKS: Update.
Caught by Bob Proulx' build daemons, analysis and suggested fix
by Stéphane Chazelas.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2008-10-28 22:45:12 +01:00
Eric Blake
2376807bbd Use m4_map_args in more places.
* lib/m4sugar/m4sugar.m4 (m4_defn, m4_dumpdef, m4_popdef)
(m4_undefine, m4_combine): Use m4_map_args, rather than
m4_foreach.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-28 14:02:47 -06:00
Eric Blake
0b08f40fc7 Override m4 1.4.x dumpdef, as it breaks autom4te.
* lib/m4sugar/m4sugar.m4 (m4_dumpdef): New implementation.
* doc/autoconf.texi (Redefined M4 Macros) <m4_dumpdef>: Mention
semantic differences as well as m4_dumpdefs.
* NEWS: Likewise.
* tests/m4sugar.at (m4@&t@_dumpdef): New test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-28 14:02:34 -06:00
Eric Blake
0a951c9da7 Allow m4sugar to be used without autom4te, such as in bison.
* lib/m4sugar/m4sugar.m4 (m4_text_wrap, m4_qlen): Document that
alternate escape sequences can be used.
(m4_text_box): Likewise.  Don't output quadrigraphs.
(m4_qdelta): Delete unused macro.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-28 13:45:45 -06:00
Paolo Bonzini
1415907c2d add m4_stack_foreach and m4_stack_foreach_lifo
* lib/m4sugar/m4sugar.m4 (_m4_stack_reverse): New from _m4_copy.
(m4_stack_foreach, m4_stack_foreach_lifo): New.
(m4_copy): Use m4_stack_foreach and m4_curry.
(_m4_dumpdefs_down, _m4_dumpdefs_up): Remove.
(m4_dumpdefs): Rewrite using m4_stack_foreach_lifo.
* tests/m4sugar.at (m4_stack_foreach): New test.
2008-10-28 18:29:25 +01:00
Paolo Bonzini
29e6e30d37 use a shell function for AC_TYPE_INTx_T
* lib/autoconf/types.m4 (_AC_TYPE_INT_BODY, _AC_TYPE_UNSIGNED_INT_BODY): New.
(_AC_TYPE_INT, _AC_TYPE_UNSIGNED_INT): Define and use a shell function.
2008-10-28 14:58:23 +01:00
Paolo Bonzini
09012d045b Fix AS_ESCAPE usage together with AC_INCLUDES_DEFAULT.
* lib/autoconf/general.m4 (AC_CHECK_DECL): Fix AS_ESCAPE usage.
* lib/autoconf/headers.m4 (_AC_CHECK_HEADER_MONGREL,
_AC_CHECK_HEADER_NEW): Likewise.
* lib/autoconf/types.m4 (_AC_CHECK_TYPE_NEW, AC_CHECK_MEMBER): Likewise.
2008-10-28 14:52:30 +01:00
Paolo Bonzini
37dd5e9c49 use a shell function for AC_CHECK_MEMBER
* lib/autoconf/types.m4 (_AC_CHECK_MEMBER_BODY): New.
(AC_CHECK_MEMBER): Define and use a shell function.
2008-10-28 13:22:54 +01:00
Eric Blake
d783e51764 Prefer m4_fatal over AC_FATAL.
* lib/autoconf/types.m4 (AC_CHECK_SIZEOF, AC_CHECK_ALIGNOF)
(AC_CHECK_MEMBER): Use non-obsolete macro name.
* lib/autoconf/fortran.m4 (_AC_LIST_MEMBER_IF): Likewise.
* lib/autoconf/general.m4 (AC_REQUIRE_AUX_FILE, AC_SUBST):
Likewise.
* lib/autoconf/lang.m4 (_AC_LANG_DISPATCH): Likewise.
* lib/autoconf/status.m4 (_AC_CONFIG_DEPENDENCY_DEFAULT)
(_AC_CONFIG_UNIQUE, _AC_CONFIG_REGISTER_DEST): Likewise.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-27 17:22:40 -06:00
Eric Blake
cb34ecf15c Avoid raw carriage return in scripts.
* lib/autoconf/status.m4 (_AC_OUTPUT_FILES_PREPARE): Generate CR
via tr, rather than with literal byte.
* THANKS: Update.
Reported by Steven R. Loomis; patch suggested by Thomas Dickey.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-27 16:34:58 -06:00
Eric Blake
cfa144a955 Use AS_VAR_ARITH.
* lib/autotest/general.m4 (at_func_arith): Delete; replace all
clients with AS_VAR_ARITH instead.
* lib/autoconf/general.m4 (_AC_COMPUTE_INT_COMPILE): Use new
macro.
* lib/autoconf/programs.m4 (_AC_FEATURE_CHECK_LENGTH): Likewise.
* tests/torture.at (Torturing config.status): Likewise.
* tests/tools.at (autom4te --force): Likewise.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-27 16:11:59 -06:00
Eric Blake
bc9d68de41 Add AS_VAR_ARITH.
* lib/m4sugar/m4sh.m4 (_AS_VAR_ARITH_PREPARE, _AS_VAR_ARITH_WORKS)
(AS_VAR_ARITH): New macros.
(_AS_PREPARE, AS_PREPARE): Emit preparation.
* tests/m4sh.at (AS@&t@_VAR_ARITH): New test.
* doc/autoconf.texi (Polymorphic Variables) <AS_VAR_ARITH>:
Document new macro.
(Limitations of Usual Tools) <expr>: Mention portability problem
if first argument starts with -.
(Shell Substitutions) <$((expression))>: Mention it.
* NEWS: Likewise.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-27 16:11:56 -06:00
Eric Blake
cf99ea9775 Use read, rather than cat, for safe one-line files.
* lib/autotest/general.m4 (AT_CLEANUP): Avoid a fork, since it is
known that the file has only one line and no \.
* lib/autoconf/general.m4 (_AC_COMPUTE_INT_RUN): Likewise.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-27 16:04:12 -06:00
Paolo Bonzini
281988f2e2 use a shell function for AC_COMPUTE_INT
* lib/autoconf/general.m4 (_AC_COMPUTE_INT_COMPILE, _AC_COMPUTE_INT_RUN): Add
IF-SUCCESS argument.
(_AC_COMPUTE_INT_BODY): New.
(AC_COMPUTE_INT): Define and use a shell function.
2008-10-27 19:33:17 +01:00
Paolo Bonzini
c8cc5be07a use a shell function for AC_CHECK_TYPE
* lib/autoconf/types.m4 (_AC_CHECK_TYPE_NEW_BODY): Extract
test body here.  Move head comment of _AC_CHECK_TYPE_NEW here.
(_AC_CHECK_TYPE_NEW): Define a shell function and call it.
2008-10-27 16:05:00 +01:00
Paolo Bonzini
e90bd84ac8 use a shell function for AC_CHECK_DECL
* lib/autoconf/general.m4 (_AC_CHECK_DECL_BODY): New.
(AC_CHECK_DECL): Use a shell function.
2008-10-27 16:04:56 +01:00
Paolo Bonzini
439f33b1c3 use a shell function for the rest of AC_CHECK_HEADER
* lib/autoconf/headers.m4 (_AC_CHECK_HEADER_OLD, _AC_CHECK_HEADER_NEW):
Use a shell function.
2008-10-27 16:02:37 +01:00
Paolo Bonzini
57079f4e33 Use a shell function for _AC_CHECK_HEADER_MONGREL.
* lib/autoconf/headers.m4 (_AC_CHECK_HEADER_MONGREL_BODY): New
macro.
(_AC_CHECK_HEADER_MONGREL): Use a shell function.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-25 07:45:31 -06:00
Eric Blake
ce2d0f043c Simplify _AS_PREPARE handling of functions.
* lib/m4sugar/m4sh.m4 (AS_REQUIRE_SHELL_FN): Factor...
(_AS_REQUIRE_SHELL_FN): ...into new helper macro.
(_AS_PREPARE): Temporarily redefine AS_REQUIRE_SHELL_FN to make
this task easier.
(_AS_LINENO_PREPARE): Make more efficient.
(_AS_MKDIR_P_PREPARE): Simplify use in _AS_PREPARE.
(_AS_UNSET_PREPARE): Avoid blank newline.
(AS_INIT): Emit as_func_unset alongside other functions.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-25 06:45:57 -06:00
Eric Blake
8425d6363b Fix m4 underquoting in AC_PROG_INSTALL.
* lib/autoconf/programs.m4 (AC_PROG_INSTALL): Produce accurate
character ranges.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 17:14:40 -06:00
Eric Blake
89e95fc78b Speed up AC_CHECK_HEADER.
* lib/autoconf/headers.m4 (AC_CHECK_HEADER): Factor out $@.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 16:41:20 -06:00
Paolo Bonzini
2509abe0dc Use a shell function for AC_CHECK_FUNC.
* lib/autoconf/functions.m4 (_AC_CHECK_FUNC_BODY): New macro.
(AC_CHECK_FUNC): Use a shell function.
* lib/autoconf/c.m4 (AC_LANG_SOURCE(C)): Reduce number of forks.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 15:26:25 -06:00
Eric Blake
6369d61222 Work around fact that gnulib-tool doesn't use m4_copy.
* lib/autoconf/general.m4 (AC_LIBOBJ, AC_LIBSOURCES): Defun, not
define, so that an initial location is present, to account for
fact that gnulib-tool pushes another AC_DEFUN'd macro on top.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 12:09:48 -06:00
Eric Blake
b4bb9caba2 Make m4_defun_init more robust.
* lib/m4sugar/m4sugar.m4 (m4_defun_init): Handle indirect macro
names, and correct number of arguments.
(m4_copy): Also set up location of the copy.
(m4_defun): When copied, use current macro name, not original.
* tests/m4sugar.at (m4@&t@_require: one-shot initialization):
Update test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 11:24:32 -06:00
Eric Blake
d0c5f482d5 Optimize clients of AS_REQUIRE.
* lib/m4sugar/m4sugar.m4 (m4_defun): Add undocumented third
argument.
(m4_defun_init): New undocumented macro.
* lib/m4sugar/m4sh.m4 (_AS_ECHO_LOG, AS_MESSAGE, AS_BASENAME)
(_AS_DIRNAME_EXPR, AS_DIRNAME, AS_ECHO, AS_ECHO_N, AS_TEST_X)
(AS_LN_S, AS_MKDIR_P, _AS_PATH_WALK, AS_VERSION_COMPARE)
(AS_TR_SH, AS_TR_CPP, AS_VAR_APPEND, AS_VAR_PUSHDEF): Use it to
simplify these macros once the one-shot initialization is
complete.
* tests/m4sugar.at (m4@&t@_require: one-shot initialization): New
test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 07:13:17 -06:00
Eric Blake
2922868b72 Improve m4_copy.
* lib/m4sugar/m4sugar.m4 (m4_copy): Add second implementation for
public use.
(_m4_copy): New macro, which preserves pushdef stacks.
(_m4_defun_pro_outer): Bypass it, for speed.
(m4_init): Bypass new implementation, since it breaks on m4_defn.
* bin/autoupdate.in (handle_autoconf_macros): Likewise.
* lib/autoconf/general.m4 (AC_PREREQ): Undefine before redefining,
now that m4_copy checks this.
* doc/autoconf.texi (Redefined M4 Macros) <m4_copy>: Document
this, as well as m4_rename.
* lib/autoconf/autoconf.m4 (m4_copy): Temporarily redefine when
renaming builtins.
* NEWS: Likewise.
* tests/m4sugar.at (m4@&t@_defn): Enhance test.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 06:41:49 -06:00
Eric Blake
21bd2e490b AC_FUNC_GETGROUPS: Revert regression.
* lib/autoconf/functions.m4 (AC_FUNC_GETGROUPS): Only set
ac_cv_func_getgroups_works=no when it is not available.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-24 05:42:10 -06:00
Eric Blake
58a97ecfca Whitespace cleanup.
* lib/autoconf/fortran.m4: Consistently use tabs.

Signed-off-by: Eric Blake <ebb9@byu.net>
2008-10-23 19:58:40 -06:00