mirror of
https://github.com/json-c/json-c.git
synced 2026-04-03 04:19:07 +08:00
Set cmake policy CMP0075, to have check_include_file use the value of CMAKE_REQUIRED_LIBRARIES (currently, adds -lm). See issue #510.
This commit is contained in:
@@ -19,6 +19,12 @@ if(POLICY CMP0054)
|
|||||||
cmake_policy(SET CMP0054 NEW)
|
cmake_policy(SET CMP0054 NEW)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# Include file check macros honor CMAKE_REQUIRED_LIBRARIES
|
||||||
|
# i.e. the check_include_file() calls will include -lm when checking.
|
||||||
|
if(POLICY CMP0075)
|
||||||
|
cmake_policy(SET CMP0075 NEW)
|
||||||
|
endif()
|
||||||
|
|
||||||
include(CTest)
|
include(CTest)
|
||||||
|
|
||||||
if (CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME AND BUILD_TESTING AND
|
if (CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME AND BUILD_TESTING AND
|
||||||
|
|||||||
Reference in New Issue
Block a user