summaryrefslogtreecommitdiff
path: root/cpp/CMakeLists.txt
diff options
context:
space:
mode:
authorStephen D. Huston <shuston@apache.org>2010-06-17 20:59:45 +0000
committerStephen D. Huston <shuston@apache.org>2010-06-17 20:59:45 +0000
commitac2f86fa29b4033393acbfee4095790eb81ef469 (patch)
treedac87b9868bfec02acfde97ce011c57d07a970f3 /cpp/CMakeLists.txt
parent38301cf57474bae7c0bd60bd6e259fe2ac9e2a26 (diff)
downloadqpid-python-ac2f86fa29b4033393acbfee4095790eb81ef469.tar.gz
Change warning C4996 from level 1 to level 4. This is the "warning C4996: 'std::equal': Function call with parameters that may be unsafe" warning. The "safe" replacements are only available on Windows, so can't be portably used. If the conditions are violated run-time errors are thrown, so these aren't totally ignored. Changing them to level 4 makes it possible for someone to easily find them all in a build if desired.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@955742 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/CMakeLists.txt')
-rw-r--r--cpp/CMakeLists.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt
index dbed67efea..68ac7b317a 100644
--- a/cpp/CMakeLists.txt
+++ b/cpp/CMakeLists.txt
@@ -30,6 +30,15 @@ set (qpidc_version ${QPID_VERSION_MAJOR}.${QPID_VERSION_MINOR})
enable_testing()
include (CTest)
+if (MSVC)
+ # Change warning C4996 from level 1 to level 4. These are real and shouldn't
+ # be completely ignored, but they're pretty well checked out and will throw
+ # a run-time error if violated.
+ # "warning C4996: 'std::equal': Function call with parameters that may
+ # be unsafe..."
+ add_definitions(/w44996)
+endif (MSVC)
+
# Overall packaging/install options.
# This section also has all the setup for various packaging-specific options.
set (CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")