autoconf-patches
[Top][All Lists]
Advanced

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

patches/76-default-CC.patch


From: Akim Demaille
Subject: patches/76-default-CC.patch
Date: Thu, 14 Dec 2000 11:20:19 +0100

Index: ChangeLog
from  Akim Demaille  <address@hidden>
        * aclang.m4 (AC_LANG(C), AC_LANG(C++), AC_LANG(Fortran 77))
        (AC_PROG_CPP, AC_PROG_CXXCPP, AC_PROG_GCC_TRADITIONAL)
        (_AC_PROG_CC_G, AC_PROG_CC_C_O, _AC_PROG_CXX_G, AC_PROG_CC_STDC):
        Don't use `${CC-cc}' since now the AC_REQUIRE machinery guarantees
        that $CC is defined.  And if not, it's a bug which must be
        observable.
        * acspecific.m4 (AC_SYS_LARGEFILE): Likewise.

Index: aclang.m4
===================================================================
RCS file: /cvs/autoconf/aclang.m4,v
retrieving revision 1.95
diff -u -u -r1.95 aclang.m4
--- aclang.m4 2000/12/13 12:36:54 1.95
+++ aclang.m4 2000/12/14 10:11:09
@@ -183,8 +183,8 @@
 m4_define([AC_LANG(C)],
 [ac_ext=c
 ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
-ac_link='${CC-cc} -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS 
conftest.$ac_ext $LIBS >&AS_MESSAGE_LOG_FD'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext 
$LIBS >&AS_MESSAGE_LOG_FD'
 ac_compiler_gnu=$ac_cv_[]_AC_LANG_ABBREV[]_compiler_gnu
 ])

@@ -210,8 +210,8 @@
 m4_define([AC_LANG(C++)],
 [ac_ext=cc
 ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 
>&AS_MESSAGE_LOG_FD'
-ac_link='${CXX-g++} -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS 
conftest.$ac_ext $LIBS >&AS_MESSAGE_LOG_FD'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS 
conftest.$ac_ext $LIBS >&AS_MESSAGE_LOG_FD'
 ac_compiler_gnu=$ac_cv_[]_AC_LANG_ABBREV[]_compiler_gnu
 ])

@@ -235,8 +235,8 @@
 # -------------------
 m4_define([AC_LANG(Fortran 77)],
 [ac_ext=f
-ac_compile='${F77-f77} -c $FFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
-ac_link='${F77-f77} -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext 
$LIBS >&AS_MESSAGE_LOG_FD'
+ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
+ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS 
>&AS_MESSAGE_LOG_FD'
 ac_compiler_gnu=$ac_cv_[]_AC_LANG_ABBREV[]_compiler_gnu
 ])

@@ -768,7 +768,7 @@
   AC_CACHE_VAL(ac_cv_prog_CPP,
   [dnl
     # Double quotes because CPP needs to be expanded
-    for CPP in "${CC-cc} -E" "${CC-cc} -E -traditional-cpp" "/lib/cpp"
+    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
     do
       _AC_PROG_PREPROC_WORKS()
       if test -z "$ac_cpp_err"; then
@@ -848,7 +848,7 @@
 [ac_test_CFLAGS=${CFLAGS+set}
 ac_save_CFLAGS=$CFLAGS
 CFLAGS="-g"
-AC_CACHE_CHECK(whether ${CC-cc} accepts -g, ac_cv_prog_cc_g,
+AC_CACHE_CHECK(whether $CC accepts -g, ac_cv_prog_cc_g,
                [_AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [ac_cv_prog_cc_g=yes],
                                                         [ac_cv_prog_cc_g=no])])
 if test "$ac_test_CFLAGS" = set; then
@@ -873,7 +873,7 @@
 # -----------------------
 AC_DEFUN([AC_PROG_GCC_TRADITIONAL],
 [if test $ac_cv_c_compiler_gnu = yes; then
-    AC_CACHE_CHECK(whether ${CC-cc} needs -traditional,
+    AC_CACHE_CHECK(whether $CC needs -traditional,
       ac_cv_prog_gcc_traditional,
 [  ac_pattern="Autoconf.*'x'"
   AC_EGREP_CPP($ac_pattern, [#include <sgtty.h>
@@ -908,7 +908,7 @@
 # Make sure it works both with $CC and with simple cc.
 # We do the test twice because some compilers refuse to overwrite an
 # existing .o file with -o, though they will create one.
-ac_try='${CC-cc} -c conftest.$ac_ext -o conftest.$ac_objext 
>&AS_MESSAGE_LOG_FD'
+ac_try='$CC -c conftest.$ac_ext -o conftest.$ac_objext >&AS_MESSAGE_LOG_FD'
 if AC_TRY_EVAL(ac_try) &&
    test -f conftest.$ac_objext && AC_TRY_EVAL(ac_try);
 then
@@ -966,7 +966,7 @@
   AC_CACHE_VAL(ac_cv_prog_CXXCPP,
   [dnl
     # Double quotes because CXXCPP needs to be expanded
-    for CXXCPP in "${CXX-g++} -E" "/lib/cpp"
+    for CXXCPP in "$CXX -E" "/lib/cpp"
     do
       _AC_PROG_PREPROC_WORKS()
       if test -z "$ac_cpp_err"; then
@@ -1041,7 +1041,7 @@
 [ac_test_CXXFLAGS=${CXXFLAGS+set}
 ac_save_CXXFLAGS=$CXXFLAGS
 CXXFLAGS="-g"
-AC_CACHE_CHECK(whether ${CXX-g++} accepts -g, ac_cv_prog_cxx_g,
+AC_CACHE_CHECK(whether $CXX accepts -g, ac_cv_prog_cxx_g,
                [_AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
                                    [ac_cv_prog_cxx_g=yes],
                                    [ac_cv_prog_cxx_g=no])])
@@ -1223,7 +1223,7 @@
 dnl FIXME: can't do this because then AC_AIX won't work due to a
 dnl circular dependency.
 dnl AC_BEFORE([$0], [AC_PROG_CPP])
-AC_MSG_CHECKING([for ${CC-cc} option to accept ANSI C])
+AC_MSG_CHECKING([for $CC option to accept ANSI C])
 AC_CACHE_VAL(ac_cv_prog_cc_stdc,
 [ac_cv_prog_cc_stdc=no
 ac_save_CC=$CC
@@ -1508,7 +1508,7 @@
 char *s = x(teststring);],
               [ac_cv_c_stringize=no],
               [ac_cv_c_stringize=yes])])
-if test "${ac_cv_c_stringize}" = yes; then
+if test $ac_cv_c_stringize = yes; then
   AC_DEFINE(HAVE_STRINGIZE, 1,
             [Define if cpp supports the ANSI @%:@ stringizing operator.])
 fi
@@ -1751,12 +1751,12 @@
       subroutine foo_bar()
       return
       end],
-[mv conftest.${ac_objext} cf77_test.${ac_objext}
+[mv conftest.$ac_objext cf77_test.$ac_objext

   AC_LANG_PUSH(C)

   ac_save_LIBS=$LIBS
-  LIBS="cf77_test.${ac_objext} $FLIBS $LIBS"
+  LIBS="cf77_test.$ac_objext $FLIBS $LIBS"

   ac_success=no
   for ac_foobar in foobar FOOBAR; do
Index: acspecific.m4
===================================================================
RCS file: /cvs/autoconf/acspecific.m4,v
retrieving revision 1.324
diff -u -u -r1.324 acspecific.m4
--- acspecific.m4 2000/12/14 09:39:33 1.324
+++ acspecific.m4 2000/12/14 10:11:21
@@ -660,7 +660,7 @@
     ac_cv_sys_largefile_CC,
     [ac_cv_sys_largefile_CC=no
      if test "$GCC" != yes; then
-       ac_save_CC=${CC-cc}
+       ac_save_CC=$CC
        while :; do
         # IRIX 6.2 and later do not support large files by default,
         # so use the C compiler's -n32 option if that helps.



reply via email to

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