-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
52 lines (45 loc) · 1.12 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
cmake_minimum_required(VERSION 3.17)
project(cub3D C)
set(CMAKE_CXX_STANDARD 89)
find_library(OPENGL_FRAMEWORK OpenGL)
find_library(APPKIT_FRAMEWORK AppKit)
find_library(SDL2_FRAMEWORK SDL2)
include_directories(headers)
include_directories(libraries/gnl)
include_directories(libraries/libft)
include_directories(libraries/mlx)
include_directories(libraries/sound)
include_directories(libraries/zlib)
include_directories(libraries/sdl2/SDL2.framework/Headers)
set(LINK_LIBRARIES ${CMAKE_SOURCE_DIR}/libraries)
set(SRCS
src/cub3d.c
src/parser.c
src/texture.c
src/events.c
src/timer.c
src/world.c
src/renderer.c
src/utils.c
src/player.c
src/mouse.c
src/collisions.c
src/story.c
src/battle.c
src/font.c
src/hud.c
src/key.c
src/raycaster.c
src/screenshot.c
src/battle_v3.c
src/mouse_event.c)
add_executable(${PROJECT_NAME} main.c ${SRCS})
target_link_libraries(${PROJECT_NAME}
${OPENGL_FRAMEWORK}
${APPKIT_FRAMEWORK}
${SDL2_FRAMEWORK}
${LINK_LIBRARIES}/sound/sound.a
${LINK_LIBRARIES}/zlib/libz.a
${LINK_LIBRARIES}/gnl/gnl.a
${LINK_LIBRARIES}/libft/libft.a
${LINK_LIBRARIES}/mlx/libmlx.a)