mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-22 09:39:43 +01:00
Remove use of add_definitions
I thought all of these were removed earlier but apparently not. Anyways, add_definitions is bad because it pollutes the definitions of every single target, we should be using target_compile_definitions instead.
This commit is contained in:
parent
69a31731ee
commit
b4226631b9
1 changed files with 3 additions and 3 deletions
|
@ -220,7 +220,7 @@ if(NOT OFFICIAL_BUILD)
|
|||
add_dependencies(VVVVVV GenerateVersion)
|
||||
|
||||
# This lets Version.h know that Version.h.out exists
|
||||
add_definitions(-DVERSION_H_OUT_EXISTS)
|
||||
target_compile_definitions(VVVVVV PRIVATE -DVERSION_H_OUT_EXISTS)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
@ -236,9 +236,9 @@ if(ENABLE_WARNINGS)
|
|||
endif()
|
||||
|
||||
if(CUSTOM_LEVEL_SUPPORT STREQUAL "NO_EDITOR")
|
||||
add_definitions(-DNO_EDITOR)
|
||||
target_compile_definitions(VVVVVV PRIVATE -DNO_EDITOR)
|
||||
elseif(CUSTOM_LEVEL_SUPPORT STREQUAL "DISABLED")
|
||||
add_definitions(-DNO_CUSTOM_LEVELS -DNO_EDITOR)
|
||||
target_compile_definitions(VVVVVV PRIVATE -DNO_CUSTOM_LEVELS -DNO_EDITOR)
|
||||
endif()
|
||||
|
||||
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
|
||||
|
|
Loading…
Reference in a new issue