Skip to content

Commit af06c90

Browse files
committed
Make use of CMP0167 optional to support older versions of CMake
1 parent 34bd17d commit af06c90

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

cmake/modules/3rdPartyFunctions.cmake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ endif ()
77
set(THIRD_PARTY_FUNCTIONS_MODULE_LOADED YES)
88

99
# prefer upstream find module of Boost
10-
cmake_policy(SET CMP0167 NEW)
10+
if (POLICY CMP0167)
11+
cmake_policy(SET CMP0167 NEW)
12+
endif ()
1113

1214
cmake_policy(SET CMP0067 NEW) # make check_cxx_source_compiles() pick up the variables for the C++ version
1315
include(CheckCXXSourceCompiles)

0 commit comments

Comments
 (0)