CMake: Remove duplicate and unused defines
Remove unused CMake code to get number of mono source files. wxUSE_BASE=1 is also defined in wx_set_target_properties. There seems no reason to define _LIB and DLL_EXPORTS, wx does not use it. They were probably added because the vcxproj files have them.
This commit is contained in:
@@ -271,7 +271,7 @@ function(wx_set_target_properties target_name)
|
||||
endif()
|
||||
|
||||
# Set common compile definitions
|
||||
target_compile_definitions(${target_name} PRIVATE WXBUILDING _LIB)
|
||||
target_compile_definitions(${target_name} PRIVATE WXBUILDING)
|
||||
if(target_name_short STREQUAL "mono" AND wxUSE_GUI)
|
||||
target_compile_definitions(${target_name} PRIVATE wxUSE_GUI=1 wxUSE_BASE=1)
|
||||
elseif(wxTARGET_IS_PLUGIN)
|
||||
@@ -350,9 +350,9 @@ function(wx_set_target_properties target_name)
|
||||
if(wxBUILD_SHARED)
|
||||
string(TOUPPER ${target_name_short} target_name_upper)
|
||||
if(target_name_short STREQUAL "mono")
|
||||
target_compile_definitions(${target_name} PRIVATE DLL_EXPORTS WXMAKINGDLL)
|
||||
target_compile_definitions(${target_name} PRIVATE WXMAKINGDLL)
|
||||
elseif(NOT wxTARGET_IS_PLUGIN)
|
||||
target_compile_definitions(${target_name} PRIVATE DLL_EXPORTS WXMAKINGDLL_${target_name_upper})
|
||||
target_compile_definitions(${target_name} PRIVATE WXMAKINGDLL_${target_name_upper})
|
||||
endif()
|
||||
target_compile_definitions(${target_name} INTERFACE WXUSINGDLL)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user