summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2013-07-29 13:02:08 +0000
committerAaron Ballman <aaron@aaronballman.com>2013-07-29 13:02:08 +0000
commitcc6933bd31634851b792f11cdb166be96b8be7d2 (patch)
tree3ac5c97708b445d5a4eb395b02539b873ee619a1 /cmake
parentcf48cf23de9207e4000df91aadc0beaa0989e33d (diff)
downloadexternal_llvm-cc6933bd31634851b792f11cdb166be96b8be7d2.zip
external_llvm-cc6933bd31634851b792f11cdb166be96b8be7d2.tar.gz
external_llvm-cc6933bd31634851b792f11cdb166be96b8be7d2.tar.bz2
Re-application of 187310. Re-enabling warning C4275 for MSVC 11 and up, but not MSVC 10 since it is still required there.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187354 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake')
-rw-r--r--cmake/modules/HandleLLVMOptions.cmake11
1 files changed, 8 insertions, 3 deletions
diff --git a/cmake/modules/HandleLLVMOptions.cmake b/cmake/modules/HandleLLVMOptions.cmake
index 97824a1..931fcdc 100644
--- a/cmake/modules/HandleLLVMOptions.cmake
+++ b/cmake/modules/HandleLLVMOptions.cmake
@@ -151,10 +151,16 @@ endif()
if( MSVC )
include(ChooseMSVCCRT)
- if( MSVC11 )
+ if( MSVC10 )
+ # MSVC 10 will complain about headers in the STL not being exported, but
+ # will not complain in MSVC 11.
+ add_llvm_definitions(
+ -wd4275 # Suppress 'An exported class was derived from a class that was not exported.'
+ )
+ elseif( MSVC11 )
add_llvm_definitions(-D_VARIADIC_MAX=10)
endif()
-
+
# Add definitions that make MSVC much less annoying.
add_llvm_definitions(
# For some reason MS wants to deprecate a bunch of standard functions...
@@ -176,7 +182,6 @@ if( MSVC )
-wd4503 # Suppress ''identifier' : decorated name length exceeded, name was truncated'
-wd4624 # Suppress ''derived class' : destructor could not be generated because a base class destructor is inaccessible'
-wd4800 # Suppress ''type' : forcing value to bool 'true' or 'false' (performance warning)'
- -wd4275 # Suppress 'An exported class was derived from a class that was not exported.'
# Promoted warnings.
-w14062 # Promote 'enumerator in switch of enum is not handled' to level 1 warning.