-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
51 lines (44 loc) · 1.89 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
cmake_minimum_required(VERSION 3.10)
project(feur VERSION 0.0)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED True)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D__USE_MINGW_ANSI_STDIO=1")
file(GLOB_RECURSE SRC_FILES "${CMAKE_SOURCE_DIR}/feur/src/*.cpp"
"${CMAKE_SOURCE_DIR}/feur/src/*.hpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/*.cpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/*.hpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/State/*.cpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/State/*.hpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/Interactable/*.cpp"
"${CMAKE_SOURCE_DIR}/feur/src/Engine/Interactable/*.hpp")
add_executable(${PROJECT_NAME} ${SRC_FILES})
include_directories(${CMAKE_SOURCE_DIR}/feur/vendor/sfml/include)
set(SFML_LIB_DIR "${CMAKE_SOURCE_DIR}/feur/vendor/sfml/lib")
set(SFML_DLL_DIR "${CMAKE_SOURCE_DIR}/feur/vendor/sfml/bin")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
target_link_libraries(${PROJECT_NAME}
"${SFML_LIB_DIR}/openal32.lib"
"${SFML_LIB_DIR}/sfml-audio-d.lib"
"${SFML_LIB_DIR}/sfml-graphics-d.lib"
"${SFML_LIB_DIR}/sfml-system-d.lib"
"${SFML_LIB_DIR}/sfml-window-d.lib"
"${SFML_DLL_DIR}/openal32.dll"
"${SFML_DLL_DIR}/sfml-audio-d-2.dll"
"${SFML_DLL_DIR}/sfml-graphics-d-2.dll"
"${SFML_DLL_DIR}/sfml-system-d-2.dll"
"${SFML_DLL_DIR}/sfml-window-d-2.dll"
)
else()
target_link_libraries(${PROJECT_NAME}
"${SFML_LIB_DIR}/openal32.lib"
"${SFML_LIB_DIR}/sfml-audio.lib"
"${SFML_LIB_DIR}/sfml-graphics.lib"
"${SFML_LIB_DIR}/sfml-system.lib"
"${SFML_LIB_DIR}/sfml-window.lib"
"${SFML_DLL_DIR}/openal32.dll"
"${SFML_DLL_DIR}/sfml-audio-2.dll"
"${SFML_DLL_DIR}/sfml-graphics-2.dll"
"${SFML_DLL_DIR}/sfml-system-2.dll"
"${SFML_DLL_DIR}/sfml-window-2.dll"
)
endif()