-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
31 lines (22 loc) · 871 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
cmake_minimum_required(VERSION 3.20)
project(LearnVulkan)
set (CMAKE_EXPORT_COMPILE_COMMANDS ON)
set (CMAKE_CXX_STANDARD 17)
set (CMAKE_BUILD_TYPE "Debug")
find_package(Vulkan REQUIRED)
find_package(GLM REQUIRED)
include_directories(${GLM_INCLUDE_DIRS})
link_directories(${GLM_LIBRARY_DIRS})
add_definitions(${GLM_DEFINITIONS})
add_subdirectory($ENV{GLFW3_ROOT} ./bin)
include_directories($ENV{GLFW3_ROOT}/include)
file (GLOB_RECURSE SRC_FILES CONFIGURE_DEPENDS
${PROJECT_SOURCE_DIR}/source/*.cpp
)
file (GLOB_RECURSE HEADER_FILES CONFIGURE_DEPENDS
${PROJECT_SOURCE_DIR}/headers/*.h
)
add_executable(LearnVulkan)
target_sources(LearnVulkan PRIVATE ${SRC_FILES} ${HEADER_FILES})
target_include_directories(LearnVulkan PRIVATE ${PROJECT_SOURCE_DIR}/headers)
target_link_libraries(LearnVulkan PRIVATE Vulkan::Vulkan ${GLM_LIBRARIES} glfw ${GLFW_LIBRARIES})