? diff.out ? autoconf.texi.3 ? autoconf.texi.1 ? autoconf.texi.2 Index: autoconf.texi =================================================================== RCS file: /cvs/autoconf/doc/autoconf.texi,v retrieving revision 1.441 diff -u -r1.441 autoconf.texi --- autoconf.texi 2001/04/10 03:33:26 1.441 +++ autoconf.texi 2001/04/11 01:20:37 @@ -758,7 +758,7 @@ @noindent is incorrect: here, the first argument of @code{AC_COMPILE_IFELSE} is @samp{char b[10];} and will be expanded once, which results in address@hidden b10;}. (There was a idiom common in Autoconf's past to address@hidden b10;}. (There was an idiom common in Autoconf's past to address this issue via the M4 @code{changequote} primitive, but do not use it!) Let's take a closer look: the author meant the first argument to be understood as a literal, and therefore it must be quoted twice: @@ -803,8 +803,6 @@ # Process this file with autoconf to produce a configure script. @end example -Such comments will be included in the generated @file{configure} script. - @node configure.ac Layout, , Autoconf Language, Writing configure.ac @subsection Standard @file{configure.ac} Layout @@ -1027,7 +1025,7 @@ @end example @noindent -If you want to disable @command{autoconf}'s defaults and @code{WARNING}, +If you want to disable @command{autoconf}'s defaults and @code{WARNINGS}, but (for example) enable the warnings about obsolete constructs, you would use @option{-W none,obsolete}. @@ -2058,6 +2056,7 @@ @end group @end example address@hidden (Be careful if you copy these lines directly into your Makefile, as you will need to convert the indented lines to start with the tab character.) @@ -2459,6 +2458,7 @@ @example ./config.status host.h object.h @end example address@hidden to create the links. @end defmac @@ -8041,30 +8041,31 @@ Unless the macro is short, try to leave the closing @samp{])} at the beginning of a line, followed by a comment that repeats the name of the -macro being defined. If you want to avoid the new-line which is then -introduced, use @code{dnl}. Better yet, use @samp{[]dnl} @emph{even} -inside of parentheses: because of the M4 evaluation rules, the address@hidden might otherwise be appended to the result of the macro -evaluation (e.g., leading to @samp{yesdnl} instead of @samp{yes}). For -instance, instead of: +macro being defined. This introduces an additional newline in address@hidden; normally, that is not a problem, but if you want to +remove it you can use @samp{[]dnl} on the last line. You can similarly +use @samp{[]dnl} after a macro call to remove its newline. @samp{[]dnl} +is recommended instead of @samp{dnl} to ensure that M4 does not +interpret the @samp{dnl} as being attached to the preceding text or +macro output. For example, instead of: @example AC_DEFUN([AC_PATH_X], [AC_MSG_CHECKING([for X]) AC_REQUIRE_CPP() address@hidden cut...} address@hidden ...omitted...} AC_MSG_RESULT([libraries $x_libraries, headers $x_includes]) fi]) @end example @noindent -write: +you would write: @example AC_DEFUN([AC_PATH_X], -[AC_REQUIRE_CPP()dnl +[AC_REQUIRE_CPP()[]dnl AC_MSG_CHECKING([for X]) address@hidden cut...} address@hidden ...omitted...} AC_MSG_RESULT([libraries $x_libraries, headers $x_includes]) fi[]dnl ])# AC_PATH_X @@ -8073,12 +8074,11 @@ If the macro is long, try to split it into logical chunks. Typically, macros that 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. +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: +In order to highlight the recommended coding style, here is a macro +written the old way: @example dnl Check for EMX on OS/2.