summaryrefslogtreecommitdiff
path: root/lib/interception
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2012-06-25 12:57:43 +0000
committerChandler Carruth <chandlerc@gmail.com>2012-06-25 12:57:43 +0000
commit821f21b7cdd0bcc91102f08c8ee0773fd9273046 (patch)
tree80a764617a18c891ef4c36670b4374d879199c34 /lib/interception
parente7539bf38e82db273708c5007bdb226c1a280b54 (diff)
Cleanup the handling of CFLAGS even more in the cmake build for ASan.
Add the initial support for building ASan tests. The first change here is to try to get the CFLAGS to more closely match those used by the old Makefile. There are probably still goofs here, ASan folks, your review would be appreciated. The second big change is to add support for building both instrumentation based an non-instrumentation based unittests for ASan. They are built a bit differently from how the old makefiles managed things. Specifically, there are two binaries, one for the non-instrumented case, and one for the instrumented case. Also, the instrumented unit tests rely on the host compiler supporting AddressSanitizer's intrumentation pass. This is kind-of gross, but I don't know of a better way yet. I've mailed llvmdev to discuss this issue. One big caveat is that the detection logic currently doesn't work. I've commented it out temporarily as I'd like to get feedback from the ASan developers, etc. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@159134 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/interception')
-rw-r--r--lib/interception/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/interception/CMakeLists.txt b/lib/interception/CMakeLists.txt
index 4a0d2cdd2..c0dd0dbd1 100644
--- a/lib/interception/CMakeLists.txt
+++ b/lib/interception/CMakeLists.txt
@@ -13,7 +13,7 @@ if (APPLE)
list(APPEND INTERCEPTION_SOURCES mach_override/mach_override.c)
endif ()
-set(INTERCEPTION_CFLAGS "-fvisibility=hidden")
+set(INTERCEPTION_CFLAGS "-fPIC -fno-exceptions -funwind-tables -fvisibility=hidden")
set(INTERCEPTION_COMMON_DEFINITIONS
INTERCEPTION_HAS_EXCEPTIONS=1)