Pass -D SDL when SDL is used

Update the Qt build to use the same define
so that common files can use it.
This commit is contained in:
Gabriel 2014-12-18 23:59:22 +01:00
parent a074c06f68
commit 3859b4713a
3 changed files with 4 additions and 3 deletions

View File

@ -764,6 +764,7 @@ elseif(SDL2_FOUND)
set(TargetBin PPSSPPSDL)
# Require SDL
include_directories(${SDL2_INCLUDE_DIR})
add_definitions(-DSDL)
set(nativeExtra ${nativeExtra}
SDL/SDLJoystick.h
SDL/SDLJoystick.cpp

View File

@ -38,7 +38,7 @@ macx|equals(PLATFORM_NAME, "linux") {
PRE_TARGETDEPS += $$CONFIG_DIR/libCommon.a $$CONFIG_DIR/libCore.a $$CONFIG_DIR/libGPU.a $$CONFIG_DIR/libNative.a
CONFIG += link_pkgconfig
packagesExist(sdl2) {
DEFINES += QT_HAS_SDL
DEFINES += SDL
SOURCES += $$P/SDL/SDLJoystick.cpp
HEADERS += $$P/SDL/SDLJoystick.h
PKGCONFIG += sdl2
@ -54,7 +54,7 @@ unix:contains(QT_CONFIG, system-zlib) {
}
# Qt Multimedia (if SDL is not found)
!contains(DEFINES, QT_HAS_SDL) {
!contains(DEFINES, SDL) {
lessThan(QT_MAJOR_VERSION,5):!exists($$[QT_INSTALL_HEADERS]/QtMultimedia) {
# Fallback to mobility audio
CONFIG += mobility

2
native

@ -1 +1 @@
Subproject commit c958ca6b4c05364c1c2a4e3eda5b355328ec8049
Subproject commit 3a400fdd381cd27f0f138e52c7e363ae182b3b5d