diff options
author | Alexey Samsonov <samsonov@google.com> | 2012-08-08 09:46:51 +0000 |
---|---|---|
committer | Alexey Samsonov <samsonov@google.com> | 2012-08-08 09:46:51 +0000 |
commit | 4750230ac605e9327b08e5e5855901c5445d86a8 (patch) | |
tree | 214f98c1b21caf5c7cf341e8e3122def4f0bdbfd /compiler-rt/lib/interception | |
parent | 90653a192088088bf7f5373e26ecde4bac205285 (diff) | |
download | bcm5719-llvm-4750230ac605e9327b08e5e5855901c5445d86a8.tar.gz bcm5719-llvm-4750230ac605e9327b08e5e5855901c5445d86a8.zip |
[Sanitizer] cleanup CMake files for interception and sanitizer_common helper libraries
llvm-svn: 161485
Diffstat (limited to 'compiler-rt/lib/interception')
-rw-r--r-- | compiler-rt/lib/interception/CMakeLists.txt | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/compiler-rt/lib/interception/CMakeLists.txt b/compiler-rt/lib/interception/CMakeLists.txt index 033b05fc1b3..3ebeb61f08e 100644 --- a/compiler-rt/lib/interception/CMakeLists.txt +++ b/compiler-rt/lib/interception/CMakeLists.txt @@ -13,25 +13,30 @@ if (APPLE) list(APPEND INTERCEPTION_SOURCES mach_override/mach_override.c) endif () -set(INTERCEPTION_CFLAGS "-fPIC -fno-exceptions -funwind-tables -fvisibility=hidden") -if (SUPPORTS_NO_VARIADIC_MACROS_FLAG) - set(INTERCEPTION_CFLAGS "${INTERCEPTION_CFLAGS} -Wno-variadic-macros") -endif () +set(INTERCEPTION_CFLAGS + -O3 + -fPIC + -fno-exceptions + -funwind-tables + -fvisibility=hidden + ) +if(SUPPORTS_NO_VARIADIC_MACROS_FLAG) + list(APPEND INTERCEPTION_CFLAGS -Wno-variadic-macros) +endif() -set(INTERCEPTION_COMMON_DEFINITIONS - INTERCEPTION_HAS_EXCEPTIONS=1) +set(INTERCEPTION_COMMON_DEFINITIONS) if(CAN_TARGET_X86_64) add_library(RTInterception.x86_64 OBJECT ${INTERCEPTION_SOURCES}) - set_property(TARGET RTInterception.x86_64 PROPERTY COMPILE_FLAGS - "${INTERCEPTION_CFLAGS} ${TARGET_X86_64_CFLAGS}") - set_property(TARGET RTInterception.x86_64 APPEND PROPERTY COMPILE_DEFINITIONS - ${INTERCEPTION_COMMON_DEFINITIONS}) + set_target_compile_flags(RTInterception.x86_64 + ${INTERCEPTION_CFLAGS} ${TARGET_X86_64_CFLAGS}) + set_property(TARGET RTInterception.x86_64 APPEND PROPERTY + COMPILE_DEFINITIONS ${INTERCEPTION_COMMON_DEFINITIONS}) endif() if(CAN_TARGET_I386) add_library(RTInterception.i386 OBJECT ${INTERCEPTION_SOURCES}) - set_property(TARGET RTInterception.i386 PROPERTY COMPILE_FLAGS - "${INTERCEPTION_CFLAGS} ${TARGET_I386_CFLAGS}") - set_property(TARGET RTInterception.i386 APPEND PROPERTY COMPILE_DEFINITIONS - ${INTERCEPTION_COMMON_DEFINITIONS}) + set_target_compile_flags(RTInterception.i386 + ${INTERCEPTION_CFLAGS} ${TARGET_I386_CFLAGS}) + set_property(TARGET RTInterception.i386 APPEND PROPERTY + COMPILE_DEFINITIONS ${INTERCEPTION_COMMON_DEFINITIONS}) endif() |