JungleOpenSourceProjectDemo.../CMakeLists.txt

29 lines
891 B
CMake
Raw Permalink Normal View History

2024-04-26 22:14:41 +08:00
cmake_minimum_required(VERSION 3.5)
project(jungle)
2024-04-27 11:39:29 +08:00
FILE (STRINGS "./deps/bullet3/VERSION" BULLET_VERSION)
set(BUILD_BULLET3 ON)
#set(BULLET_VERSION 3.26)
2024-04-26 22:14:41 +08:00
2024-04-27 11:39:29 +08:00
include_directories(jungle PRIVATE ./deps/bullet3/src/)
2024-04-26 22:14:41 +08:00
2024-04-27 11:39:29 +08:00
add_subdirectory(./deps/glfw/)
add_subdirectory(./deps/bullet3/src/)
add_subdirectory(./deps/glm)
2024-04-26 22:14:41 +08:00
##test target##
2024-04-27 13:56:55 +08:00
add_executable(jungle ./src/main.cpp ./deps/glad/src/glad.c)
target_include_directories(jungle PRIVATE ./inc/)
2024-04-26 22:14:41 +08:00
#glfw dep
add_dependencies(jungle glfw)
target_include_directories(jungle PRIVATE ./deps/glfw/include/ ./deps/glad/include/ ./inc)
target_link_libraries(jungle glfw)
#bullet dep
2024-04-27 11:39:29 +08:00
add_dependencies(jungle Bullet3Common)
2024-04-26 22:14:41 +08:00
target_include_directories(jungle PRIVATE ./deps/bullet3/src/)
2024-04-27 11:39:29 +08:00
target_link_libraries(jungle Bullet3Common)
2024-04-26 22:14:41 +08:00
#glm dep
add_dependencies(jungle glm)
target_include_directories(jungle PRIVATE ./deps/glm/)
target_link_libraries(jungle glm)