diff options
author | Dan Liew <daniel.liew@imperial.ac.uk> | 2015-04-09 16:32:26 +0100 |
---|---|---|
committer | Dan Liew <daniel.liew@imperial.ac.uk> | 2015-04-09 19:48:58 +0100 |
commit | f8a909c0cfe6a1ca0ef9bf952401fc561a48fc8f (patch) | |
tree | 3f1429c697add146442a6271eca1e1d4b743b20c | |
parent | cac3cc670bf19a055286353d55db3317ccb2301c (diff) | |
download | klee-f8a909c0cfe6a1ca0ef9bf952401fc561a48fc8f.tar.gz |
Try to fix using the compiler KLEE's configure script detected again!
My first attempt in b41cf33b6b726fd97e502c5c4818f5feeea0284b was wrong because setting the CC and CXX Makefile variables in Makefile.config.in did not work because LLVM's Makefile.config would override them. Also detecting the C compiler is unnecessary because we already do this (bitcode compiler detection)
-rw-r--r-- | Makefile.common | 6 | ||||
-rw-r--r-- | Makefile.config.in | 9 |
2 files changed, 10 insertions, 5 deletions
diff --git a/Makefile.common b/Makefile.common index 964a7475..80e6e8a1 100644 --- a/Makefile.common +++ b/Makefile.common @@ -27,6 +27,12 @@ LLVMCC := $(LLVMGCC) LLVMCXX := $(LLVMGXX) endif +# Deliberately override the host compiler +# so that we use what was detected when KLEE was configured +# and not LLVM. +CC := $(KLEE_HOST_C_COMPILER) +CXX := $(KLEE_HOST_CXX_COMPILER) + # Needed to build runtime library using clang (gnu89 is the gcc default) C.Flags += -std=gnu89 diff --git a/Makefile.config.in b/Makefile.config.in index efedd505..fb8dbdb2 100644 --- a/Makefile.config.in +++ b/Makefile.config.in @@ -53,6 +53,10 @@ RUNTIME_ENABLE_PROFILING := KLEE_BITCODE_C_COMPILER := @KLEE_BITCODE_C_COMPILER@ KLEE_BITCODE_CXX_COMPILER := @KLEE_BITCODE_CXX_COMPILER@ +# Host compiler +KLEE_HOST_C_COMPILER := @KLEE_HOST_C_COMPILER@ +KLEE_HOST_CXX_COMPILER := @KLEE_HOST_CXX_COMPILER@ + # A list of "features" which tests can check for in XFAIL: TEST_FEATURE_LIST := @@ -65,11 +69,6 @@ endif # disable unwind test TEST_FEATURE_LIST += no-unwind -# Deliberately override the host compiler -# so that we use what was detected when KLEE was configured -# and not LLVM. -CC := @KLEE_HOST_C_COMPILER@ -CXX := @KLEE_HOST_CXX_COMPILER@ CFLAGS := @CFLAGS@ -Wall -g CXXFLAGS := @CXXFLAGS@ -g -Wall LDFLAGS := @LDFLAGS@ -g |