Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Simplify CMake Policies
  • Loading branch information
tresf committed Jul 23, 2023
commit 343f4d0735aefd98c72ac935013c1d3f89c49ad3
18 changes: 7 additions & 11 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,13 @@ SET(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/modules" ${CMAKE_MODULE_PATH})
SET(LMMS_BINARY_DIR ${CMAKE_BINARY_DIR})
SET(LMMS_SOURCE_DIR ${CMAKE_SOURCE_DIR})

IF(COMMAND CMAKE_POLICY)
CMAKE_POLICY(SET CMP0005 NEW)
CMAKE_POLICY(SET CMP0003 NEW)
IF (CMAKE_MAJOR_VERSION GREATER 2)
CMAKE_POLICY(SET CMP0026 NEW)
CMAKE_POLICY(SET CMP0045 NEW)
CMAKE_POLICY(SET CMP0050 OLD)
ENDIF()
CMAKE_POLICY(SET CMP0020 NEW)
CMAKE_POLICY(SET CMP0057 NEW)
ENDIF(COMMAND CMAKE_POLICY)
CMAKE_POLICY(SET CMP0005 NEW) # Preprocessor definition values are now escaped automatically
CMAKE_POLICY(SET CMP0003 NEW) # Libraries linked via full path no longer produce linker search paths.
CMAKE_POLICY(SET CMP0026 NEW) # Disallow use of the LOCATION property for build targets.
CMAKE_POLICY(SET CMP0045 NEW) # Error on non-existent target in get_target_property.
CMAKE_POLICY(SET CMP0050 OLD) # Disallow add_custom_command SOURCE signatures.
CMAKE_POLICY(SET CMP0020 NEW) # Automatically link Qt executables to qtmain target on Windows.
CMAKE_POLICY(SET CMP0057 NEW) # Support new if() IN_LIST operator.


# Import of windows.h breaks min()/max()
Expand Down