Finished configuring cmake for resources folder.

This commit is contained in:
Samuel Walker 2024-09-01 23:04:05 -06:00
parent 259048a195
commit b09dbb4804
2 changed files with 3 additions and 1 deletions

View File

@ -7,7 +7,9 @@ FILE(GLOB Sources src/*.cpp)
FILE(GLOB Resources res/*) FILE(GLOB Resources res/*)
add_executable(raycaster ${Sources} deps/glad/src/glad.c) add_executable(raycaster ${Sources} deps/glad/src/glad.c)
configure_file(src/RaycasterConfig.h.in RaycasterConfig.h) configure_file(src/RaycasterConfig.h.in RaycasterConfig.h)
FILE(COPY ${Resources} DESTINATION ${CMAKE_BINARY_DIR}/res) add_custom_command(TARGET raycaster POST_BUILD COMMAND ${CMAKE_COMMAND} ARGS -E rm -r ${CMAKE_BINARY_DIR}/res)
add_custom_command(TARGET raycaster POST_BUILD COMMAND ${CMAKE_COMMAND} ARGS -E copy_directory ${CMAKE_SOURCE_DIR}/res/ ${CMAKE_BINARY_DIR}/res)
#FILE(COPY ${Resources} DESTINATION ${CMAKE_BINARY_DIR}/res)
target_include_directories(raycaster PUBLIC target_include_directories(raycaster PUBLIC
"${PROJECT_BINARY_DIR}" "${PROJECT_BINARY_DIR}"
"deps/glfw/include" "deps/glfw/include"

View File