From 08969e32d18b4aa6da1df88053637a8a6fa3a128 Mon Sep 17 00:00:00 2001 From: Riyyi Date: Mon, 13 May 2024 13:56:48 +0200 Subject: [PATCH] Meta: Add assimp dependency --- .gitmodules | 3 +++ README.org | 1 + vendor/CMakeLists.txt | 13 ++++++++++++- vendor/assimp | 1 + 4 files changed, 17 insertions(+), 1 deletion(-) create mode 160000 vendor/assimp diff --git a/.gitmodules b/.gitmodules index 8661ac7..397cb07 100644 --- a/.gitmodules +++ b/.gitmodules @@ -19,3 +19,6 @@ [submodule "inferno/vendor/ruc"] path = vendor/ruc url = https://github.com/Riyyi/ruc +[submodule "inferno/vendor/assimp"] + path = vendor/assimp + url = https://github.com/assimp/assimp diff --git a/README.org b/README.org index 797345e..b56fca9 100644 --- a/README.org +++ b/README.org @@ -33,6 +33,7 @@ $ cmake .. && make * Libraries +- [[https://github.com/assimp/assimp][assimp]] # - [[https://github.com/bulletphysics/bullet3][Bullet]] - [[https://github.com/skypjack/entt][EnTT]] - [[https://github.com/Dav1dde/glad][glad]] diff --git a/vendor/CMakeLists.txt b/vendor/CMakeLists.txt index f20163e..5a9d270 100644 --- a/vendor/CMakeLists.txt +++ b/vendor/CMakeLists.txt @@ -9,6 +9,16 @@ add_subdirectory(glfw) # Add RUC target to project add_subdirectory(ruc) +# assimp options +option(ASSIMP_BUILD_ASSIMP_VIEW OFF) +option(ASSIMP_BUILD_TESTS OFF) +option(ASSIMP_INSTALL OFF) +option(ASSIMP_INSTALL_PDB OFF) +option(ASSIMP_WARNINGS_AS_ERRORS OFF) + +# Add assimp target to project +add_subdirectory(assimp) + # Define engine source files file(GLOB_RECURSE GLAD "glad/*.c") file(GLOB LUA "lua/lua/*.c") @@ -19,6 +29,7 @@ set(ENGINE_SOURCES ${GLAD} ${LUA}) add_library(${ENGINE}-dependencies ${ENGINE_SOURCES}) target_include_directories(${ENGINE}-dependencies PUBLIC + "assimp/include" "glad/include" "lua") -target_link_libraries(${ENGINE}-dependencies glfw ruc ruc-test) +target_link_libraries(${ENGINE}-dependencies glfw ruc ruc-test assimp) diff --git a/vendor/assimp b/vendor/assimp new file mode 160000 index 0000000..762ad8e --- /dev/null +++ b/vendor/assimp @@ -0,0 +1 @@ +Subproject commit 762ad8e9b7d8749c17dedd3e0b9a32b933949e8f