aboutsummaryrefslogtreecommitdiffstats
path: root/autoconf
diff options
context:
space:
mode:
authorJim Grosbach <grosbach@apple.com>2008-10-02 22:56:44 +0000
committerJim Grosbach <grosbach@apple.com>2008-10-02 22:56:44 +0000
commite4c032e38e3eef6c84b7a7529406a8c306d0e6a5 (patch)
tree2030e2081eafe70baeea869342ed46d853eea8b0 /autoconf
parent1a7f65b1aa8aa739b31cf7d0b2c8db87b435a6b8 (diff)
downloadexternal_llvm-e4c032e38e3eef6c84b7a7529406a8c306d0e6a5.zip
external_llvm-e4c032e38e3eef6c84b7a7529406a8c306d0e6a5.tar.gz
external_llvm-e4c032e38e3eef6c84b7a7529406a8c306d0e6a5.tar.bz2
Add support for Canadian Cross builds where the host executables are not
runnable on the build machine. There are a few bits that need built for the build environment (TableGen). This patch builds those bits, and the associated libraries, for the build environment as well as the (usual) host environment. Thanks to Eric C. and Devang P. for pre-commit review. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56975 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'autoconf')
-rw-r--r--autoconf/configure.ac8
1 files changed, 8 insertions, 0 deletions
diff --git a/autoconf/configure.ac b/autoconf/configure.ac
index 35d017e..88d095e 100644
--- a/autoconf/configure.ac
+++ b/autoconf/configure.ac
@@ -242,6 +242,14 @@ dnl Check for build platform executable suffix if we're crosscompiling
if test "$cross_compiling" = yes; then
AC_SUBST(LLVM_CROSS_COMPILING, [1])
AC_BUILD_EXEEXT
+ ac_build_prefix=${build_alias}-
+ AC_CHECK_PROG(BUILD_CXX, ${ac_build_prefix}g++, ${ac_build_prefix}g++)
+ if test -z "$BUILD_CXX"; then
+ AC_CHECK_PROG(BUILD_CXX, g++, g++)
+ if test -z "$BUILD_CXX"; then
+ AC_CHECK_PROG(BUILD_CXX, c++, c++, , , /usr/ucb/c++)
+ fi
+ fi
else
AC_SUBST(LLVM_CROSS_COMPILING, [0])
fi