For zstd and hiredis downloaded from the Internet, set cmake policy
CMP0135 to NEW to set the timestamps of extracted archive members to the
time of extraction to suppress the cmake dev warning on newer versions
of cmake.
Check that the policy exists so that this works on older versions of
cmake.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
return()
endif()
+if(POLICY CMP0135)
+ # Set timestamps on extracted files to time of extraction.
+ cmake_policy(SET CMP0135 NEW)
+endif()
+
set(hiredis_FOUND FALSE)
if(HIREDIS_FROM_INTERNET AND NOT HIREDIS_FROM_INTERNET STREQUAL "AUTO")
return()
endif()
+if(POLICY CMP0135)
+ # Set timestamps on extracted files to time of extraction.
+ cmake_policy(SET CMP0135 NEW)
+endif()
+
set(zstd_FOUND FALSE)
if(ZSTD_FROM_INTERNET AND NOT ZSTD_FROM_INTERNET STREQUAL "AUTO")