summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-03-13 14:15:02 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-03-13 14:15:10 (GMT)
commit40ad7cabc69149391d95c39bb578def164c80441 (patch)
treeb0d8bffa77c1d88d0f1b3d9e5659b20e8d8e3732
parentc0f53f743edd0946a267e384da0d390753409533 (diff)
parent2c280acdf836b661cdfb2bdf3a3b5f1fda15a424 (diff)
downloadCMake-40ad7cabc69149391d95c39bb578def164c80441.zip
CMake-40ad7cabc69149391d95c39bb578def164c80441.tar.gz
CMake-40ad7cabc69149391d95c39bb578def164c80441.tar.bz2
Merge topic 'ignore-json-deprecated-warnings'
2c280acdf8 JsonCpp: Ignore deprecation warnings Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3091
-rw-r--r--CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 69e3064..abf62bf 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -538,6 +538,10 @@ macro (CMAKE_BUILD_UTILITIES)
message(FATAL_ERROR
"CMAKE_USE_SYSTEM_JSONCPP is ON but a JsonCpp is not found!")
endif()
+ if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
+ set_property(TARGET JsonCpp::JsonCpp APPEND PROPERTY
+ INTERFACE_COMPILE_OPTIONS -Wno-deprecated-declarations)
+ endif()
set(CMAKE_JSONCPP_LIBRARIES JsonCpp::JsonCpp)
else()
set(CMAKE_JSONCPP_LIBRARIES cmjsoncpp)