From 4825e586fbfc575bbc7d169db5cde77cf8a804d4 Mon Sep 17 00:00:00 2001 From: Chuck Atkins <chuck.atkins@kitware.com> Date: Thu, 20 Apr 2017 14:13:22 -0400 Subject: [PATCH] Patch GTest for warnings with newer CMake versions --- thirdparty/GTest/googletest/CMakeLists.txt | 5 +++++ thirdparty/GTest/googletest/googletest/CMakeLists.txt | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/thirdparty/GTest/googletest/CMakeLists.txt b/thirdparty/GTest/googletest/CMakeLists.txt index 8d2b552ef..4eddf7585 100644 --- a/thirdparty/GTest/googletest/CMakeLists.txt +++ b/thirdparty/GTest/googletest/CMakeLists.txt @@ -1,5 +1,10 @@ cmake_minimum_required(VERSION 2.6.2) +# CMake 3.0, Let the project command manage version variables. +if(POLICY CMP0048) + cmake_policy(SET CMP0048 NEW) +endif() + project( googletest-distribution ) enable_testing() diff --git a/thirdparty/GTest/googletest/googletest/CMakeLists.txt b/thirdparty/GTest/googletest/googletest/CMakeLists.txt index 621d0f042..f8f5e582e 100644 --- a/thirdparty/GTest/googletest/googletest/CMakeLists.txt +++ b/thirdparty/GTest/googletest/googletest/CMakeLists.txt @@ -47,6 +47,11 @@ endif() project(gtest CXX C) cmake_minimum_required(VERSION 2.6.2) +# CMake 3.0, Let the project command manage version variables. +if(POLICY CMP0048) + cmake_policy(SET CMP0048 NEW) +endif() + if (COMMAND set_up_hermetic_build) set_up_hermetic_build() endif() -- GitLab