diff options
author | Michael Kruse <llvm@meinersbur.de> | 2015-07-21 12:22:36 +0000 |
---|---|---|
committer | Michael Kruse <llvm@meinersbur.de> | 2015-07-21 12:22:36 +0000 |
commit | 441357dca2fbe9cac5c178efe533314e520623cd (patch) | |
tree | 60555b494623baaebdda7d21c6ee08e99762a264 /polly/CMakeLists.txt | |
parent | 61a992439df7e621ec785ade310538aeca291aa9 (diff) | |
download | llvm-441357dca2fbe9cac5c178efe533314e520623cd.tar.gz |
Remove gcc-specific flags from Visual Studio build
Remove the flags -fno-exceptions -fno-rtti and add the equivalent for
compiling with MSVC.
Reviewers: grosser
llvm-svn: 242775
Diffstat (limited to 'polly/CMakeLists.txt')
-rw-r--r-- | polly/CMakeLists.txt | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/polly/CMakeLists.txt b/polly/CMakeLists.txt index 5c0270ebe404..64c671e26b40 100644 --- a/polly/CMakeLists.txt +++ b/polly/CMakeLists.txt @@ -75,10 +75,13 @@ if (CMAKE_COMPILER_IS_GNUCXX) # FIXME: Turn off exceptions, RTTI: # -fno-exceptions -fno-rtti set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-common -Woverloaded-virtual -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti") +elseif (MSVC) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHs-c-") + add_definitions("-D_HAS_EXCEPTIONS=0") +else () + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-exceptions -fno-rtti") endif () -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-exceptions -fno-rtti") - # Define the FLAGS for the compilation of isl and imath # # Those are the only C files we have in the repository. Hence, we can just use |