diff options
author | Brad King <brad.king@kitware.com> | 2015-02-20 13:15:43 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-02-20 13:22:02 (GMT) |
commit | a5768442636c7fe909e8afc205fd19ac13b9fbc2 (patch) | |
tree | af7f2655b1115192c0435d74c3965169b0eafba0 /CMakeLists.txt | |
parent | da92cdab5206d0556822ee12350636300ec73160 (diff) | |
download | CMake-a5768442636c7fe909e8afc205fd19ac13b9fbc2.zip CMake-a5768442636c7fe909e8afc205fd19ac13b9fbc2.tar.gz CMake-a5768442636c7fe909e8afc205fd19ac13b9fbc2.tar.bz2 |
FindJsonCpp: Drop new module due to upstream jsoncpp providing package
Since jsoncpp 0.7.0 (2014-11-20) the upstream may provide a CMake
package configuration file such that find_package(jsoncpp) will find a
jsoncppConfig.cmake file. In order to avoid conflicting with this
(especially on case-insensitive filesystems), and since we always prefer
projects to provide package config files (that they maintain), it is
better to not provide FindJsonCpp publicly.
Move FindJsonCpp into a private source directory that is not installed
so that we can still use it for building CMake itself.
Reported-by: Ryan Pavlik <ryan.pavlik@gmail.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index e61621d..1250a94 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -382,10 +382,8 @@ macro (CMAKE_BUILD_UTILITIES) #--------------------------------------------------------------------- # Build jsoncpp library. if(CMAKE_USE_SYSTEM_JSONCPP) - if(EXISTS ${CMAKE_ROOT}/Modules/FindJsonCpp.cmake) - find_package(JsonCpp) - elseif(NOT CMAKE_VERSION VERSION_LESS 3.0) - include(${CMake_SOURCE_DIR}/Modules/FindJsonCpp.cmake) + if(NOT CMAKE_VERSION VERSION_LESS 3.0) + include(${CMake_SOURCE_DIR}/Source/Modules/FindJsonCpp.cmake) else() message(FATAL_ERROR "CMAKE_USE_SYSTEM_JSONCPP requires CMake >= 3.0") endif() |