mirror of
https://github.com/SFML/SFML.git
synced 2024-12-01 15:51:04 +08:00
65fef85b30
CMake doesn't require absolute paths so we can safely remove SRCROOT and let implicit relative pathing achieve the same result with less work on our part.
17 lines
469 B
CMake
17 lines
469 B
CMake
# all source files
|
|
set(SRC Island.cpp)
|
|
|
|
# define the island target
|
|
sfml_add_example(island GUI_APP
|
|
SOURCES ${SRC}
|
|
DEPENDS SFML::Graphics
|
|
RESOURCES_DIR resources)
|
|
|
|
# external dependency headers
|
|
target_include_directories(island SYSTEM PRIVATE ${PROJECT_SOURCE_DIR}/examples/island)
|
|
|
|
# link against pthread
|
|
if(SFML_OS_LINUX OR SFML_OS_FREEBSD OR SFML_OS_MACOSX)
|
|
target_link_libraries(island PRIVATE pthread)
|
|
endif()
|