CMake 3.16 deprecation warnings

Description

Upgrading our projects CMake version to 3.16 has now produced the following deprecation warnings in the cassandra cmake cpp-driver:

CMake Deprecation Warning at <path>/datastax/cassandra-cpp-driver/cmake/modules/CppDriver.cmake:350 (cmake_policy):
The OLD behavior for policy CMP0042 will be removed from a future version
of CMake.

The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
Call Stack (most recent call first):
<path>/datastax/cassandra-cpp-driver/CMakeLists.txt:14 (CassPolicies)

CMake Deprecation Warning at <path>/datastax/cassandra-cpp-driver/cmake/modules/CppDriver.cmake:355 (cmake_policy):
The OLD behavior for policy CMP0048 will be removed from a future version
of CMake.

The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
Call Stack (most recent call first):
<path>/datastax/cassandra-cpp-driver/CMakeLists.txt:14 (CassPolicies)

– PROJECT version: 2.14.1
– libuv version: v1.34.0
– Check if compiler accepts -pthread
– Check if compiler accepts -pthread - yes
– Found OpenSSL: /usr/lib64/libssl.so (found version "1.0.2k")
– OpenSSL version: v1.0.2k
CMake Warning (dev) at <path>/datastax/cassandra-cpp-driver/cmake/modules/CppDriver.cmake:667 (find_package):
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.

CMake variable ZLIB_ROOT is set to:

<path>/datastax/cassandra-cpp-driver/lib/zlib/;<path>/datastax/cassandra-cpp-driver/build/libs/zlib/

For compatibility, CMake is ignoring the variable.
Call Stack (most recent call first):
<path>/datastax/cassandra-cpp-driver/cmake/modules/CppDriver.cmake:113 (CassUseZlib)
<path>/datastax/cassandra-cpp-driver/CMakeLists.txt:91 (CassOptionalDependencies)
This warning is for project developers. Use -Wno-dev to suppress it.

CMake Deprecation Warning at <path>/datastax/cassandra-cpp-driver/cmake/modules/CppDriver.cmake:704 (cmake_policy):
The OLD behavior for policy CMP0054 will be removed from a future version
of CMake.

The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
Call Stack (most recent call first):
<path>datastax/cassandra-cpp-driver/CMakeLists.txt:106 (CassSetCompilerFlags)

Environment

centos 7
cmake 3.16
gcc-9
clang-9

Pull Requests

None

Assignee

Unassigned

Reporter

Josh Baldwin

Labels

None

PM Priority

None

Reproduced in

None

External issue ID

None

Doc Impact

None

Reviewer

None

Pull Request

None

Size

None

Priority

Minor
Configure