According to Paolo Bonzini on 10/30/2009 1:36 PM: > On 10/30/2009 01:00 PM, Eric Blake wrote: >> According to Ralf Wildenhues on 10/30/2009 12:31 AM: >>> Should we also document that the ACTION-IF-TRUE part of >>> AC_LINK_IFELSE allows linked programs to be inspected (not necessarily >>> run) and that of AC_COMPILE_IFELSE allows compiled objects to be >>> inspected? >> >> Hmm, those aren't done as often (about all you can do is run nm on it; >> that seems like something libtool might want to do, but who else does it >> to be worth documenting it?). > > For AC_LINK_IFELSE you could run the program if not cross-compiling. > That seems better than the AC_TRY_RUN(ac_link) that is usually done.
Clearing out some more documentation todo's from my inbox. This is now on my push queue. -- Eric Blake [email protected] +1-801-349-2682 Libvirt virtualization library http://libvirt.org
From 53b94981d6e777d65ddb7b5830301e34c35e760b Mon Sep 17 00:00:00 2001 From: Eric Blake <[email protected]> Date: Tue, 2 Mar 2010 14:00:24 -0700 Subject: [PATCH] Improve documentation on AC_{COMPILE,LINK}_IFELSE. * doc/autoconf.texi (Running the Compiler): Mention that the object file is available after a successful compile. (Running the Linker): Likewise for the linker output. Suggested by Paolo Bonzini. Signed-off-by: Eric Blake <[email protected]> --- ChangeLog | 6 ++++++ doc/autoconf.texi | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index e6bbd4e..4eae96d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2010-03-02 Eric Blake <[email protected]> + Improve documentation on AC_{COMPILE,LINK}_IFELSE. + * doc/autoconf.texi (Running the Compiler): Mention that the + object file is available after a successful compile. + (Running the Linker): Likewise for the linker output. + Suggested by Paolo Bonzini. + Fix typo in docs. * doc/autoconf.texi (Conditional constructs) <m4_ifblank>: Fix typo. diff --git a/doc/autoconf.texi b/doc/autoconf.texi index e302e1a..c4f96c8 100644 --- a/doc/autoconf.texi +++ b/doc/autoconf.texi @@ -8914,7 +8914,8 @@ Running the Compiler It is customary to report unexpected failures with @code{AC_MSG_FAILURE}. This macro does not try to link; use @code{AC_LINK_IFELSE} if you need to do that (@pxref{Running the -Linker}). +Linker}). If needed, @var{action-if-true} can further access the +just-linked object file @file{conftest.$ac_object}. This macro uses @code{AC_REQUIRE} for the compiler associated with the current language, which means that if the compiler has not yet been @@ -8959,7 +8960,8 @@ Running the Linker language (@pxref{Language Choice}) on the @var{input}, run the shell commands @var{action-if-true} on success, @var{action-if-false} otherwise. The @var{input} can be made by @code{AC_LANG_PROGRAM} and -friends. +friends. If needed, @var{action-if-true} can further access the +just-linked program file @file{conftest$ac_exeext}. @code{LDFLAGS} and @code{LIBS} are used for linking, in addition to the current compilation flags. -- 1.6.6.1
signature.asc
Description: OpenPGP digital signature
