bug-autoconf
[Top][All Lists]
Advanced

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

Re: Weird interactions between AC_PROG_CC and AC_PROG_F77


From: Stefano Lattarini
Subject: Re: Weird interactions between AC_PROG_CC and AC_PROG_F77
Date: Sun, 7 Feb 2010 13:32:21 +0100
User-agent: KMail/1.12.1 (Linux/2.6.30-2-686; KDE/4.3.2; i686; ; )

> > Of the AC_PROG_{CC,CXX,F77,FC} macros, only the first one in the
> > configure script will check for object file extension and default
> > executable file name and fail if that doesn't work.
> 
Attached there is a simple patch documenating this behaviour in the
Autoconf manual.  The usual caveat: I'm not a native speaker, so the 
wording might be suboptimal, if not botched.

Regards,
    Stefano
From f6166e39397fb2b2722327a2f6cf51d47ad2ba76 Mon Sep 17 00:00:00 2001
From: Stefano Lattarini <address@hidden>
Date: Sun, 7 Feb 2010 13:26:47 +0100
Subject: [PATCH] Document surprising behaviour of AC_PROG_{CC,CXX,F77,FC}.

* doc/autoconf.texi (Compilers and Preprocessors): Explicitly
tell that, of the macros AC_PROG_{CC,CXX,F77,FC}, only the first
expanded one will check for object file extension etc, and fail
if that doesn't work.
Initial report by Stefano Lattarini, first explaination by
Ralf Wildenhues.  Final patch by Stefano Lattarini.
---
 ChangeLog         |   11 +++++++++++
 doc/autoconf.texi |    9 +++++++++
 2 files changed, 20 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 18aa169..6f0cb40 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2010-02-07  Stefano Lattarini  <address@hidden>
+           Ralf Wildenhues  <address@hidden>
+
+       Document surprising behaviour of AC_PROG_{CC,CXX,F77,FC}.
+       * doc/autoconf.texi (Compilers and Preprocessors): Explicitly
+       tell that, of the macros AC_PROG_{CC,CXX,F77,FC}, only the first
+       expanded one will check for object file extension etc, and fail
+       if that doesn't work.
+       Initial report by Stefano Lattarini, first explaination by
+       Ralf Wildenhues.  Final patch by Stefano Lattarini.
+
 2010-01-24  Ralf Wildenhues  <address@hidden>
 
        Fix substitution of carriage return on Darwin.
diff --git a/doc/autoconf.texi b/doc/autoconf.texi
index e5cf9fd..de9792d 100644
--- a/doc/autoconf.texi
+++ b/doc/autoconf.texi
@@ -6863,6 +6863,15 @@ the executables can't be run, and cross-compilation is 
not enabled, they
 fail too.  @xref{Manual Configuration}, for more on support for cross
 compiling.
 
+Also, it's important to understand that of the macros @code{AC_PROG_CC},
address@hidden, @code{AC_PROG_F77} and @code{AC_PROG_FC}, only the
+first expanded one will check for object file extension and default
+executable file name, and fail if that doesn't work.  If one needs to know
+for sure whether any of the compilers work, then he'll need to add a
+compile, link, or run test to find out.  This behaviour may seem
+surprising, but probably it cannot be fixed without breaking backward
+compatibility in some way.
+
 @menu
 * Specific Compiler Characteristics::  Some portability issues
 * Generic Compiler Characteristics::  Language independent tests and features
-- 
1.6.5


reply via email to

[Prev in Thread] Current Thread [Next in Thread]