-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
25 lines (19 loc) · 925 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
cmake_minimum_required(VERSION 3.7)
set(PROJECT_NAME NomProjet)
project(${PROJECT_NAME})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -static")
set(CMAKE_CXX_STANDARD 14)
set(SOURCE_FILES main.cpp src/Graphics.h src/logic/Model.h input_files/in1.txt src/logic/Point.h src/logic/Node.h src/logic/Node.cpp src/logic/Utils.h src/Controller.h src/drawables/Conveyor.h src/drawables/ThickLine.h)
if (CMAKE_BUILD_TYPE STREQUAL "Release")
add_executable(${PROJECT_NAME} WIN32 ${SOURCE_FILES})
else ()
add_executable(${PROJECT_NAME} ${SOURCE_FILES})
endif ()
set(SFML_ROOT C:/CLibraries/SFML)
set(SFML_STATIC_LIBRARIES TRUE)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake_modules")
find_package(SFML 2.4 REQUIRED COMPONENTS audio graphics window system)
if (SFML_FOUND)
include_directories(${SFML_INCLUDE_DIR})
target_link_libraries(${PROJECT_NAME} ${SFML_LIBRARIES} ${SFML_DEPENDENCIES})
endif ()