cmake: set CMP0074 to NEW (for OPENSSL_ROOT in appveyor)

We have $env:OPENSSL_ROOT (env) equals to -DOPENSSL_ROOT (cmake
variable) anyway.

cmake complains:
  Policy CMP0074 is not set: find_package uses <PackageName>_ROOT variables.
  Run "cmake --help-policy CMP0074" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  Environment variable OpenSSL_ROOT is set to:
    C:/OpenSSL-Win64/bin

  For compatibility, CMake is ignoring the variable.
This warning is for project developers.  Use -Wno-dev to suppress it.

(cherry picked from commit 65904773f2bf965e2050d4d7c91e30d4f123a787)
This commit is contained in:
Azat Khuzhin 2018-11-05 18:23:31 +03:00 committed by Azat Khuzhin
parent b021b979a1
commit 3d3d1e0530
No known key found for this signature in database
GPG Key ID: B86086848EF8686D

View File

@ -27,6 +27,9 @@ endif()
if (POLICY CMP0054)
cmake_policy(SET CMP0054 NEW)
endif()
if (POLICY CMP0074)
cmake_policy(SET CMP0074 NEW)
endif()
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release