]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Patch #1239112: Correct LINKCC C++ test. Fixes #1189330.
authorMartin v. Löwis <martin@v.loewis.de>
Sun, 7 Aug 2005 21:08:54 +0000 (21:08 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Sun, 7 Aug 2005 21:08:54 +0000 (21:08 +0000)
Misc/NEWS
configure
configure.in

index 0e6c3b8a0fe834bc564fa4661bead678d9e64afd..6cb41ca73dbf15ead6586e4d7596aab504c1227d 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -93,6 +93,9 @@ Library
 Build
 -----
 
+- Bug #1189330: configure did not correctly determine the necessary
+  value of LINKCC if python was built with GCC 4.0.
+
 - Upgrade Windows build to zlib 1.2.3 which eliminates a potential security
   vulnerability in zlib 1.2.1 and 1.2.2.
 
index 1186834a3c682375853f358411357c04c2e210b9..a68ce2d646849fb894b6165aee6fe6b1ec9871c8 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Revision: 1.475.2.7 .
+# From configure.in Revision: 1.475.2.8 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.59 for python 2.4.
 #
@@ -3265,9 +3265,11 @@ then
         if test -z "$CXX"; then
               LINKCC="\$(PURIFY) \$(CC)"
         else
-              echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
-              $CXX -c conftest.$ac_ext 2>&5
-              if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
+              echo 'extern "C" void foo();int main(){foo();}' > conftest_a.cc
+              $CXX -c conftest_a.cc # 2>&5
+              echo 'void foo(){}' > conftest_b.$ac_ext
+              $CC -c conftest_b.$ac_ext # 2>&5
+              if $CC -o conftest$ac_exeext conftest_a.$ac_objext conftest_b.$ac_objext 2>&5 \
                  && test -s conftest$ac_exeext && ./conftest$ac_exeext
               then
                  LINKCC="\$(PURIFY) \$(CC)"
index a4fb112831ce94b9d0756cb13f8af01aa4263315..5ad6adbc711f252cbc740110d4eee09ed2f60233 100644 (file)
@@ -471,9 +471,11 @@ then
         if test -z "$CXX"; then
               LINKCC="\$(PURIFY) \$(CC)"
         else
-              echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
-              $CXX -c conftest.$ac_ext 2>&5
-              if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
+              echo 'extern "C" void foo();int main(){foo();}' > conftest_a.cc
+              $CXX -c conftest_a.cc # 2>&5
+              echo 'void foo(){}' > conftest_b.$ac_ext
+              $CC -c conftest_b.$ac_ext # 2>&5
+              if $CC -o conftest$ac_exeext conftest_a.$ac_objext conftest_b.$ac_objext 2>&5 \
                  && test -s conftest$ac_exeext && ./conftest$ac_exeext
               then
                  LINKCC="\$(PURIFY) \$(CC)"