Skip to content

Commit d4ef316

Browse files
authored
Silence warnings when building with CMake 3.27 (#16)
* CMake policy CMP0114 (introduced CMake 3.19) warns if ExternalProject is used with Xcode generator and is required to use Xcode 'new build system' * CMake policy CMP0135 (introduced CMake 3.24) warns if DOWNLOAD_EXTRACT_TIMESTAMP is not specified in ExternalProject.
1 parent 82d8cc6 commit d4ef316

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Diff for: cmake/HunterGate.cmake

+6
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,12 @@ function(hunter_gate_download dir)
254254
WRITE
255255
"${cmakelists}"
256256
"cmake_minimum_required(VERSION 3.5)\n"
257+
"if(POLICY CMP0114)\n"
258+
" cmake_policy(SET CMP0114 NEW)\n"
259+
"endif()\n"
260+
"if(POLICY CMP0135)\n"
261+
" cmake_policy(SET CMP0135 NEW)\n"
262+
"endif()\n"
257263
"project(HunterDownload LANGUAGES NONE)\n"
258264
"include(ExternalProject)\n"
259265
"ExternalProject_Add(\n"

0 commit comments

Comments
 (0)