wx: Move platform defines to wx setup header

Usually, this is passed as a preprocessor definition, but this is error
prone and just complicating the compiler invocation for no good reason.
This commit is contained in:
Florent Castelli
2017-02-03 22:59:34 +01:00
parent 834ec372cc
commit 5984ca26f3
3 changed files with 4 additions and 5 deletions

View File

@ -910,10 +910,7 @@ if(NOT DISABLE_WX)
# These definitions and includes are used when building dolphin against wx,
# not when building wx itself (see wxw3 CMakeLists.txt for that)
if(APPLE)
add_definitions(-D__WXOSX_COCOA__)
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Linux|FreeBSD")
add_definitions(-D__WXGTK__)
# Check for required libs
check_lib(GTHREAD2 gthread-2.0 gthread-2.0 glib/gthread.h REQUIRED)
check_lib(PANGOCAIRO pangocairo pangocairo pango/pangocairo.h REQUIRED)
@ -921,7 +918,6 @@ if(NOT DISABLE_WX)
# Required for wxUSE_STACKWALKER in Externals/wxWidgets3/wx/wxgtk.h
find_package(Backtrace REQUIRED)
elseif(WIN32)
add_definitions(-D__WXMSW__)
else()
message(FATAL_ERROR "wxWidgets in Externals is not compatible with your platform")
endif()