mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
7cd00e3630
This should not affect solidity, but with this setting all supported CMake version will use NEW policy are will be allowed to use RPATH on macOS.
28 lines
622 B
CMake
28 lines
622 B
CMake
# it must be a macro cause policies have scopes
|
|
# http://www.cmake.org/cmake/help/v3.0/command/cmake_policy.html
|
|
macro (eth_policy)
|
|
# link_directories() treats paths relative to the source dir.
|
|
cmake_policy(SET CMP0015 NEW)
|
|
|
|
if (${CMAKE_VERSION} VERSION_GREATER 3.0)
|
|
|
|
cmake_policy(SET CMP0042 NEW)
|
|
|
|
# ignore COMPILE_DEFINITIONS_<Config> properties
|
|
cmake_policy(SET CMP0043 OLD)
|
|
|
|
# allow VERSION argument in project()
|
|
cmake_policy(SET CMP0048 NEW)
|
|
|
|
endif()
|
|
|
|
if (${CMAKE_VERSION} VERSION_GREATER 3.1)
|
|
|
|
# do not interpret if() arguments as variables!
|
|
cmake_policy(SET CMP0054 NEW)
|
|
|
|
endif()
|
|
|
|
endmacro()
|
|
|