[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
insert macros within AC_PROG_CC before _AC_COMPILER_EXEEEXT
From: |
Daily, Jeff A |
Subject: |
insert macros within AC_PROG_CC before _AC_COMPILER_EXEEEXT |
Date: |
Tue, 7 Sep 2010 13:52:03 -0700 |
FYI I'm using autoconf 2.67.
Here's why I need to insert macros into AC_PROG_CC:
I have some users who refuse to use anything but Intel's icc and ifort, version
8.1. But, they have a newer GCC installed (4.1.2) which causes icc to barf
with "invalid GNU version number: 412" (causing configure to report "C compiler
cannot create executables"). The problem can be worked-around if they add
CFLAGS="-gcc-version-340". But these users want me to add this flag
conditionally during configure. But how?
AC_PROG_CC expands _AC_COMPILER_EXEEXT once. This is where the standard test
fails because of the missing flag. What I need is to test link (presumably
using AC_LINK_IFELSE) as soon as the C compiler is found, but before
_AC_COMPILER_EXEEXT is expanded.
Can this be done? I'd rather not copy-and-paste my own version of AC_PROG_CC
and insert the modifications manually (unless that truly is the only way...)
I'll need to do something similar for AC_PROG_CXX as well.
Jeff
- insert macros within AC_PROG_CC before _AC_COMPILER_EXEEEXT,
Daily, Jeff A <=