Commit ffc8f9dc by Maarten L. Hekkelman

Better support for older cmake versions

parent 288b2bb7
...@@ -61,8 +61,12 @@ set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) ...@@ -61,8 +61,12 @@ set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
option(BUILD_FOR_CCP4 "Build a version to be installed in CCP4" OFF) option(BUILD_FOR_CCP4 "Build a version to be installed in CCP4" OFF)
# Building shared libraries? # Building shared libraries?
cmake_policy(SET CMP0127 NEW) if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.22)
cmake_dependent_option(BUILD_SHARED_LIBS "Build a shared library instead of a static one" OFF "NOT (BUILD_FOR_CCP4 AND WIN32)" ON) cmake_policy(SET CMP0127 NEW)
cmake_dependent_option(BUILD_SHARED_LIBS "Build a shared library instead of a static one" OFF "NOT (BUILD_FOR_CCP4 AND WIN32)" ON)
else()
cmake_dependent_option(BUILD_SHARED_LIBS "Build a shared library instead of a static one" OFF)
endif()
# Lots of code depend on the availability of the components.cif file # Lots of code depend on the availability of the components.cif file
option(CIFPP_DOWNLOAD_CCD "Download the CCD file components.cif during installation" ON) option(CIFPP_DOWNLOAD_CCD "Download the CCD file components.cif during installation" ON)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment