Search for SDL2 in cloonelgraphics.

This commit is contained in:
King_DuckZ 2017-10-24 20:16:48 +01:00
parent ba60426cc2
commit a1b66e99f0

View file

@ -1,4 +1,7 @@
project(cloonelgraphics CXX)
include(FindPkgConfig)
pkg_search_module(SDL2 REQUIRED IMPORTED_TARGET sdl2)
add_library(${PROJECT_NAME}
texture.cpp
@ -11,13 +14,12 @@ add_library(${PROJECT_NAME}
)
target_link_libraries(${PROJECT_NAME}
PRIVATE ${SDL2_LIBRARIES}
PRIVATE PkgConfig::SDL2
PRIVATE ${PHYSFS_LIBRARY}
PRIVATE ${PNG_LIBRARIES}
)
target_include_directories(${PROJECT_NAME}
PRIVATE ${SDL2_INCLUDE_DIR}
PRIVATE ${PNG_INCLUDE_DIRS}
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}
PRIVATE ${PHYSFS_INCLUDE_DIR}