Initial commit
This commit is contained in:
34
CMakeLists.txt
Normal file
34
CMakeLists.txt
Normal file
@@ -0,0 +1,34 @@
|
||||
cmake_minimum_required(VERSION 3.21)
|
||||
|
||||
set(NAME skyjo)
|
||||
|
||||
project(${NAME} LANGUAGES CXX)
|
||||
|
||||
include(FetchContent)
|
||||
|
||||
set(ASSET_DIR ${CMAKE_CURRENT_SOURCE_DIR}/assets/)
|
||||
|
||||
# Disable sfml audio (This avoids pulling in OpenAL)
|
||||
set(SFML_BUILD_AUDIO OFF CACHE BOOL "" FORCE)
|
||||
|
||||
FetchContent_Declare(
|
||||
SFML
|
||||
GIT_REPOSITORY https://github.com/SFML/SFML.git
|
||||
GIT_TAG 2.6.1
|
||||
)
|
||||
FetchContent_MakeAvailable(SFML)
|
||||
|
||||
add_executable(${NAME}
|
||||
sources/main.cpp
|
||||
sources/CardMaker.cpp
|
||||
)
|
||||
target_link_libraries(${NAME} sfml-graphics sfml-window sfml-system)
|
||||
target_include_directories(${NAME} PUBLIC
|
||||
./includes
|
||||
)
|
||||
|
||||
target_compile_definitions(${NAME} PRIVATE
|
||||
ASSET_DIR="${ASSET_DIR}"
|
||||
)
|
||||
|
||||
install(TARGETS ${NAME})
|
||||
Reference in New Issue
Block a user