Re: RFE: configure -> dependency list on exit.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 4 Mar 2005, Stepan Kasal wrote:

Hello Hugh,


Thank you for your helpful comments. How is this, below?

        Hugh

--- ./autoconf.texi-1.880.orig	2005-03-02 10:35:08.489794000 +0000
+++ ./autoconf.texi-1.880	2005-03-04 13:06:47.185023000 +0000
@@ -7645,8 +7645,15 @@
 @section Printing Messages
 @cindex Messages, from @command{configure}

-@command{configure} scripts need to give users running them several kinds
-of information.  The following macros print messages in ways appropriate
+@command{configure} scripts need to give users running them several
+kinds of information.  Users need to know how the script is
+progressing, including the results of tests, and when the script
+completes unsuccessfully or with only partial success, they need
+ready access to information about what failed.  In particular, it is
+desirable that this sort of information not scroll away where it
+will be lost or unseen.
+
+The following macros print messages in ways appropriate
 for each kind.  The arguments to all of them get enclosed in shell
 double quotes, so the shell performs variable and back-quote
 substitution on them.
@@ -7690,6 +7697,29 @@
 @option{--quiet} or @option{--silent} option.
 @end defmac

+@defmac AC_MSG_NEED (@var{dependency-description}, @ovar{priority})
+@acindex{MSG_NEED}
+Notify the user when a test of a dependency failed, that something
+is needed.  It is recommended that the user be informed of something
+which would provide such functionality.  The message is displayed
+when the macro is expanded and at the end (@code{AC_OUTPUT}).   The
+optional @ovar{priority} is used to determine where @code{AC_OUTPUT}
+will display the message so the user sees it.  Priorities are signed,
+the nearer to -infinity the higher the priority.
+
+@example
+AC_MSG_NEED([A lexical analyser is needed by Bison, such as Flex or
+lex.])
+@c Not sure if there are sufficient []'s there....
+@end example
+@c This may be implemented with AC_MSG_NOTICE and AC_MSG_END
+
+This could be accomplished with @code{AC_MSG_NOTICE} and
+@code{AC_MSG_END}, but @code{AC_MSG_NEED} is more meaningful to the
+reader of the @file{configure.ac}, and avoids duplication of the
+message (in two macros).
+@end defmac
+
 @defmac AC_MSG_NOTICE (@var{message})
 @acindex{MSG_NOTICE}
 Deliver the @var{message} to the user.  It is useful mainly to print a
@@ -7704,6 +7734,16 @@
 @option{--quiet} or @option{--silent} option.
 @end defmac

+@defmac AC_MSG_END (@var{message}, @ovar{priority})
+@acindex{MSG_END}
+Display a message when @code{AC_OUTPUT} is called.  The messages are
+sorted by @ovar{priority}, the default being +infinity.
+@ovar{priority} is a signed quantity, the more negative the more
+important (so that for purely positive cases, 1 is top priority).
+Higher priority messages are produced later by @code{AC_OUTPUT} so
+that they do not scroll out of view.
+@end defmac
+
 @defmac AC_MSG_ERROR (@var{error-description}, @ovar{exit-status})
 @acindex{MSG_ERROR}
 Notify the user of an error that prevents @command{configure} from
@@ -7714,6 +7754,12 @@

 The @var{error-description} should start with a lower-case letter, and
 ``cannot'' is preferred to ``can't''.
+
+It is recommended that, where possible, @code{AC_MSG_END} or
+@code{AC_MSG_NEED} be used in preference to this, because exiting
+later may permit more missing dependencies to be found during one
+execution of @file{configure}, without the information being lost in
+the scroll buffer.
 @end defmac

 @defmac AC_MSG_FAILURE (@var{error-description}, @ovar{exit-status})


_______________________________________________ Autoconf mailing list Autoconf@xxxxxxx http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux