From: Akim Demaille Date: Mon, 10 Jul 2000 10:28:50 +0000 (+0000) Subject: * doc/autoconf.texi (Coding Style): Some more constraints :). X-Git-Tag: autoconf-2.50~740 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6fdbfea975f46bfd37b9b23dc9643e94d4a4e8fa;p=thirdparty%2Fautoconf.git * doc/autoconf.texi (Coding Style): Some more constraints :). --- diff --git a/ChangeLog b/ChangeLog index 72347024d..abf0b0f40 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2000-07-10 Akim Demaille + + * doc/autoconf.texi (Coding Style): Some more constraints :). + 2000-07-10 Akim Demaille * acspecific.m4 (AC_FUNC_STRERROR_R): Aaaaaaarg! Don't leave the diff --git a/acgeneral.m4 b/acgeneral.m4 index bf6144968..ef1def442 100644 --- a/acgeneral.m4 +++ b/acgeneral.m4 @@ -2192,7 +2192,7 @@ AC_DEFUN_ONCE([AC_CANONICAL_BUILD], [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_DIVERT([HELP_CANON], [[ -Hosts type: +System types: --build=BUILD configure for building on BUILD [guessed]]])dnl # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 || diff --git a/doc/autoconf.texi b/doc/autoconf.texi index 97f641c4b..e08c7e2e0 100644 --- a/doc/autoconf.texi +++ b/doc/autoconf.texi @@ -6697,6 +6697,12 @@ fi[]dnl ])# AC_PATH_X @end example +If the macro is long, try to split it into logical chunks. Typically, +macros which check for a bug in a function and prepare its +@code{AC_LIBOBJ} replacement should have an auxiliary macro to perform +this setup. + +Do not hesitate to introduce auxiliary macros to factor your code. In order to highlight this coding style, here is a macro written the old way: diff --git a/lib/autoconf/general.m4 b/lib/autoconf/general.m4 index bf6144968..ef1def442 100644 --- a/lib/autoconf/general.m4 +++ b/lib/autoconf/general.m4 @@ -2192,7 +2192,7 @@ AC_DEFUN_ONCE([AC_CANONICAL_BUILD], [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_DIVERT([HELP_CANON], [[ -Hosts type: +System types: --build=BUILD configure for building on BUILD [guessed]]])dnl # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 ||