From 8c3a9ba832eff00f1d5d3dc450cb068bad267ec8 Mon Sep 17 00:00:00 2001 From: Harry Mallon Date: Mon, 30 Oct 2023 13:58:56 +0000 Subject: [PATCH] Silence warnings when building with CMake 3.27 (#717) * HunterGate: Update embedded HunterGate to latest * Silence warnings when building with CMake 3.27 * 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. * Also integrate https://github.com/cpp-pm/gate/pull/16 applying this to HunterGate --- cmake/modules/hunter_create_cache_file.cmake | 16 ++++++++++++++++ gate | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/cmake/modules/hunter_create_cache_file.cmake b/cmake/modules/hunter_create_cache_file.cmake index 2bcb94e277..e42ddbdffa 100644 --- a/cmake/modules/hunter_create_cache_file.cmake +++ b/cmake/modules/hunter_create_cache_file.cmake @@ -195,6 +195,22 @@ function(hunter_create_cache_file cache_path) "set(CMAKE_POLICY_DEFAULT_CMP0069 NEW CACHE INTERNAL \"\")\n" ) + # CMP0114 should be set to NEW to squash CMake warnings at Xcode build time, + # without modifying source code + file( + APPEND + "${temp_path}" + "set(CMAKE_POLICY_DEFAULT_CMP0114 NEW CACHE INTERNAL \"\")\n" + ) + + # CMP0135 should be set to NEW to squash CMake warnings at build time, + # without modifying source code + file( + APPEND + "${temp_path}" + "set(CMAKE_POLICY_DEFAULT_CMP0135 NEW CACHE INTERNAL \"\")\n" + ) + # Disable package registry { ### http://www.cmake.org/cmake/help/v3.1/manual/cmake-packages.7.html#disabling-the-package-registry file( diff --git a/gate b/gate index 958e65c65f..d4ef316240 160000 --- a/gate +++ b/gate @@ -1 +1 @@ -Subproject commit 958e65c65fb659293b23c7a3c64abf3ce81e6ff1 +Subproject commit d4ef316240086b54ac5c8c91207b07cae29ab30f