Fix build error about SDL_platform.h not found.

This commit is contained in:
King_DuckZ 2017-10-24 20:25:01 +01:00
parent ee3a17fd13
commit 37f7964388
2 changed files with 6 additions and 7 deletions

@ -1 +1 @@
Subproject commit 8669e5e67476a1e6c6e6582e2fd46b1a29100b0c
Subproject commit a1b66e99f0fee32f72cb39676e1fc9c957cba96d

View file

@ -1,7 +1,7 @@
project(mycurry_gamelib CXX)
PKG_SEARCH_MODULE(SDL2 REQUIRED sdl2)
PKG_SEARCH_MODULE(SDL2IMAGE REQUIRED SDL2_image>=2.0.0)
PKG_SEARCH_MODULE(SDL2 REQUIRED IMPORTED_TARGET sdl2)
PKG_SEARCH_MODULE(SDL2IMAGE REQUIRED IMPORTED_TARGET SDL2_image>=2.0.0)
find_package(PNG REQUIRED)
add_library(${PROJECT_NAME}
@ -22,13 +22,12 @@ add_library(${PROJECT_NAME}
drawable.cpp
drawing_queue.cpp
world_moveable.cpp
collider.cpp
)
set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 14)
set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD_REQUIRED ON)
target_include_directories(${PROJECT_NAME} SYSTEM
PRIVATE ${SDL2_INCLUDE_DIR}
PRIVATE ${SDL2IMAGE_INCLUDE_DIRS}
PRIVATE ${PNG_INCLUDE_DIRS}
PRIVATE ${Boost_INCLUDE_DIRS}
)
@ -38,8 +37,8 @@ target_include_directories(${PROJECT_NAME}
)
target_link_libraries(${PROJECT_NAME}
PRIVATE ${SDL2_LIBRARIES}
PRIVATE ${SDL2IMAGE_LIBRARIES}
PRIVATE PkgConfig::SDL2
PRIVATE PkgConfig::SDL2IMAGE
PRIVATE ${PNG_LIBRARIES}
PUBLIC mycurry_toplevel
PUBLIC cloonelgraphics