all repos — mgba @ 27c7041008d77296741f08b2710b3a1f19d77160

mGBA Game Boy Advance Emulator

Make sure Qt knows where SDL2 libs are
Jeffrey Pfau jeffrey@endrift.com
Sun, 26 Oct 2014 03:51:36 -0700
commit

27c7041008d77296741f08b2710b3a1f19d77160

parent

f98d6486efee2ee4ad9d2d4b3786004cb3ee4b76

1 files changed, 6 insertions(+), 1 deletions(-)

jump to
M src/platform/qt/CMakeLists.txtsrc/platform/qt/CMakeLists.txt

@@ -4,7 +4,12 @@

set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --std=c++11") if(BUILD_SDL) - find_package(SDL 1.2 REQUIRED) + if(NOT SDL_FOUND AND NOT SDL2_FOUND) + find_package(SDL 1.2 REQUIRED) + endif() + if(SDL2_FOUND) + link_directories(${SDL2_LIBDIR}) + endif() set(PLATFORM_LIBRARY "${PLATFORM_LIBRARY};${SDL_LIBRARY};${SDLMAIN_LIBRARY}") set(PLATFORM_SRC ${PLATFORM_SRC} ${CMAKE_SOURCE_DIR}/src/platform/sdl/sdl-events.c) include_directories(${SDL_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/src/platform/sdl)