summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorFrancis Ricci <francisjricci@gmail.com>2016-09-08 15:57:22 +0000
committerFrancis Ricci <francisjricci@gmail.com>2016-09-08 15:57:22 +0000
commit92655f0385f87c6fde76d19a84a9314e9f0b637c (patch)
tree045cf356a238801dc855de43eca19e6e25fdee87 /CMakeLists.txt
parente1be16548943a26eb5c76546290b3ebe6c1ee9b3 (diff)
downloadcompiler-rt-92655f0385f87c6fde76d19a84a9314e9f0b637c.tar.gz
[compiler-rt] Don't use -fPIC when building for Windows
Summary: This flag doesn't make sense on Windows systems. Reviewers: beanz, kubabrecka, compnerd Subscribers: dberris, llvm-commits, beanz Differential Revision: https://reviews.llvm.org/D24320 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@280953 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 3 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 05bd8c0bc..7c9baadc1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -129,7 +129,9 @@ if(NOT COMPILER_RT_HAS_FUNC_SYMBOL)
endif()
# Provide some common commmandline flags for Sanitizer runtimes.
-append_list_if(COMPILER_RT_HAS_FPIC_FLAG -fPIC SANITIZER_COMMON_CFLAGS)
+if(NOT WIN32)
+ append_list_if(COMPILER_RT_HAS_FPIC_FLAG -fPIC SANITIZER_COMMON_CFLAGS)
+endif()
append_list_if(COMPILER_RT_HAS_FNO_BUILTIN_FLAG -fno-builtin SANITIZER_COMMON_CFLAGS)
append_list_if(COMPILER_RT_HAS_FNO_EXCEPTIONS_FLAG -fno-exceptions SANITIZER_COMMON_CFLAGS)
if(NOT COMPILER_RT_DEBUG)