diff options
author | Francois Pichet <pichet2000@gmail.com> | 2010-12-04 14:30:22 +0000 |
---|---|---|
committer | Francois Pichet <pichet2000@gmail.com> | 2010-12-04 14:30:22 +0000 |
commit | b361452ef9ad9453b2874cd12fc9ee65085d1f57 (patch) | |
tree | 7e38617bbb3dcd021b43b5664c8f34b650460699 /cmake/modules/LLVMProcessSources.cmake | |
parent | 983839609ffa589cda60efaea847eecede77b524 (diff) | |
download | external_llvm-b361452ef9ad9453b2874cd12fc9ee65085d1f57.zip external_llvm-b361452ef9ad9453b2874cd12fc9ee65085d1f57.tar.gz external_llvm-b361452ef9ad9453b2874cd12fc9ee65085d1f57.tar.bz2 |
Disable C++ exception handling on MSVC.
Total size of bin\Release on disk goes from 82.9 MB to 74.2 MB. (~10% saving)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120908 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake/modules/LLVMProcessSources.cmake')
-rw-r--r-- | cmake/modules/LLVMProcessSources.cmake | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/cmake/modules/LLVMProcessSources.cmake b/cmake/modules/LLVMProcessSources.cmake index e8a5a94..7bfca20 100644 --- a/cmake/modules/LLVMProcessSources.cmake +++ b/cmake/modules/LLVMProcessSources.cmake @@ -41,6 +41,9 @@ function(llvm_process_sources OUT_VAR) if( NOT LLVM_REQUIRES_EH ) if( CMAKE_COMPILER_IS_GNUCXX ) add_definitions( -fno-exceptions ) + elseif( MSVC ) + add_definitions( /EHs-c- ) + add_definitions( /D_HAS_EXCEPTIONS=0 ) endif() endif() if( NOT LLVM_REQUIRES_RTTI ) |