-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
35 lines (27 loc) · 959 Bytes
/
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
# cmake files for the "Dungeon Adventure" project.
cmake_minimum_required(VERSION 3.5.0)
# Compiler settings (this must come before calling project).
set(CMAKE_C_STANDARD 11)
project(Dungeon_Adventure)
# Bring the headers, such as termcolor.hpp into the project.
include_directories(include)
# However, the file(GLOB...) allows for wildcard additions.
file(GLOB SOURCES "src/*.c")
# Project folder completed.
set(
CMAKE_RUNTIME_OUTPUT_DIRECTORY
${CMAKE_HOME_DIRECTORY}/build
)
# Delete all generated cmake files, including the binary executable in the "build" folder.
# It does not delete project files in the "src" folder:
#
# * include
# * CMakeLists.txt
# * LICENSE
#
# run the command from the terminal: make clean-all to clean the project.
add_custom_target(clean-all
rm -rf CMakeCache.txt cmake_install.cmake Makefile CMakeFiles/
)
# Also add resources to the target so they are visible in the IDE.
add_executable(dungeonadv ${SOURCES})