aboutsummaryrefslogtreecommitdiff
path: root/libcpp/configure
diff options
context:
space:
mode:
authorJoern Rennecke <joern.rennecke@embecosm.com>2010-06-09 10:32:23 +0000
committerJoern Rennecke <amylaar@gcc.gnu.org>2010-06-09 11:32:23 +0100
commitff5dfc4869aad7bedad9e749e6eed7d5f783b970 (patch)
tree2e4596e9549c064794426f4a44005559b7d52198 /libcpp/configure
parent07b7ede0bfdf1943af80159912cbf80e691e62eb (diff)
downloadgcc-ff5dfc4869aad7bedad9e749e6eed7d5f783b970.zip
gcc-ff5dfc4869aad7bedad9e749e6eed7d5f783b970.tar.gz
gcc-ff5dfc4869aad7bedad9e749e6eed7d5f783b970.tar.bz2
re PR bootstrap/44432 ([boot with C++] configure does not check presence of host C++ compiler)
PR bootstrap/44432 * configure.ac: Before using ZW_PROG_COMPILER_DEPENDENCIES for C++, check that C++ compiler works. * configure: Regenerate. From-SVN: r160460
Diffstat (limited to 'libcpp/configure')
-rwxr-xr-xlibcpp/configure26
1 files changed, 24 insertions, 2 deletions
diff --git a/libcpp/configure b/libcpp/configure
index cf17de4..a4700e6 100755
--- a/libcpp/configure
+++ b/libcpp/configure
@@ -4400,6 +4400,29 @@ else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
fi
else
+ac_ext=cpp
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+
+
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+int i;
+_ACEOF
+if ac_fn_cxx_try_compile "$LINENO"; then :
+
+else
+ as_fn_error "C++ compiler missing or inoperational" "$LINENO" 5
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
depcc="$CXX" am_compiler_list=
am_depcomp=$ac_aux_dir/depcomp
@@ -4997,8 +5020,7 @@ ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-
-ac_ext=cpp
+ ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'