summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2016-11-13 22:27:00 +0000
committerEric Fiselier <eric@efcs.ca>2016-11-13 22:27:00 +0000
commit110520227e841104d38f826174302ff7068b2611 (patch)
treefd6ddcddffca839dbb64e0612717edb0fe39d9c7
parentcc4f512be04098946b4f875d18bd4d69cbcd7463 (diff)
Fix GCC libc++abi build
git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@286783 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--CMakeLists.txt4
-rw-r--r--test/lit.site.cfg.in1
2 files changed, 5 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b23936e..5eb0109 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -249,6 +249,10 @@ add_target_flags_if(LIBCXXABI_GCC_TOOLCHAIN
add_target_flags_if(LIBCXXABI_SYSROOT
"--sysroot=${LIBCXXABI_SYSROOT}")
+if (LIBCXXABI_TARGET_TRIPLE)
+ set(TARGET_TRIPLE "${LIBCXXABI_TARGET_TRIPLE}")
+endif()
+
# Configure compiler. Must happen after setting the target flags.
include(config-ix)
diff --git a/test/lit.site.cfg.in b/test/lit.site.cfg.in
index 57e448a..b8fb35c 100644
--- a/test/lit.site.cfg.in
+++ b/test/lit.site.cfg.in
@@ -18,6 +18,7 @@ config.enable_shared = "@LIBCXX_ENABLE_SHARED@"
config.enable_exceptions = "@LIBCXXABI_ENABLE_EXCEPTIONS@"
config.host_triple = "@LLVM_HOST_TRIPLE@"
config.target_triple = "@TARGET_TRIPLE@"
+config.use_target = len("@LIBCXXABI_TARGET_TRIPLE@") > 0
# Let the main config do the real work.
lit_config.load_config(config, "@LIBCXXABI_SOURCE_DIR@/test/lit.cfg")