-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
80 lines (66 loc) · 2.22 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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
cmake_minimum_required(VERSION 2.8.12)
set(SOURCE_FILES src/main.cpp src/TextureThing.cpp src/TextureManager.cpp src/Renderer.cpp src/Application.cpp src/Scene.cpp src/Scenes/GamePlayScene.cpp)
#set(HEADER_FILES headers/TextureThing.hpp headers/Renderer.hpp headers/TextureManager.hpp)
set(HEADER_FILES)
set(PROJ_NAME fcFrog)
project(${PROJ_NAME})
add_definitions("-std=c++11")
include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
conan_basic_setup()
add_executable(${PROJ_NAME} ${HEADER_FILES} ${SOURCE_FILES})
target_link_libraries(${PROJ_NAME} ${CONAN_LIBS})
target_include_directories(${PROJ_NAME} PRIVATE headers)
if(MSVC)
# target_compile_options(${PROJ_NAME} PRIVATE /W4 /WX)
else()
target_compile_options(${PROJ_NAME} PRIVATE -Wall -Wextra -Wpedantic -Werror)
endif()
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/higo.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/higo.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/path.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/path.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/path2.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/path2.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/profile.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/profile.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/splash_logo.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/splash_logo.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/splash_logo_small.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/splash_logo_small.png
)
add_custom_command(
TARGET ${PROJ_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/assets/ghosty.png
${CMAKE_CURRENT_BINARY_DIR}/bin/assets/ghosty.png
)