building spdlog from source

This commit is contained in:
2026-02-26 16:17:50 +01:00
parent 3935d00cb9
commit e894cc36c0
3 changed files with 16 additions and 5 deletions

2
.gitignore vendored
View File

@@ -17,3 +17,5 @@ Build/
**.csprojMakefile **.csprojMakefile
compile_commands.json compile_commands.json
Makefile Makefile
/SakuraVNE.make
/imgui.ini

View File

@@ -15,10 +15,10 @@ workspace "SakuraVNE"
IncludeDir["ImGui"] = "/libs/imgui" IncludeDir["ImGui"] = "/libs/imgui"
IncludeDir["ImGuiNodeEditor"] = "/libs/imgui-node-editor" IncludeDir["ImGuiNodeEditor"] = "/libs/imgui-node-editor"
IncludeDir["SDL3"] = "/libs/sdl3" IncludeDir["SDL3"] = "/libs/sdl3"
IncludeDir["spdlog"] = "/libs/spdlog"
include "libs/imgui" include "libs/imgui"
include "libs/imgui-node-editor" include "libs/imgui-node-editor"
--include "libs/sdl3"
project "SakuraVNE" --project under solution project "SakuraVNE" --project under solution
--location "SakuraVNE" --location "SakuraVNE"
@@ -48,6 +48,14 @@ project "SakuraVNE" --project under solution
"cmake --build \"" .. root_path .. "/build/bin-int/" .. outputdir .. "/SDL3\" --config Release -j" "cmake --build \"" .. root_path .. "/build/bin-int/" .. outputdir .. "/SDL3\" --config Release -j"
} }
prebuildcommands{
"echo ==== Building spdlog via CMake ====",
"mkdir -p \"" .. root_path .. "/build/bin/" ..outputdir .. "/spdlog\"",
"cmake -S libs/spdlog -B \"" .. root_path .. "/build/bin-int/" ..outputdir .. "/spdlog\" -DCMAKE_BUILD_TYPE=Release",
"cmake --build \"" .. root_path .. "/build/bin-int/" ..outputdir .. "/spdlog\"",
"cp \"" .. root_path .. "/build/bin-int/" .. outputdir .. "/spdlog/\"libspdlog* \"" .. root_path .. "/build/bin/" .. outputdir .. "/spdlog/\""
}
files{ files{
"%{prj.name}/src/**.h", "%{prj.name}/src/**.h",
"%{prj.name}/src/**.cpp" "%{prj.name}/src/**.cpp"
@@ -66,13 +74,15 @@ project "SakuraVNE" --project under solution
libdirs{ libdirs{
"build/bin/" .. outputdir .. "/ImGui", "build/bin/" .. outputdir .. "/ImGui",
"build/bin/" .. outputdir .. "/ImGuiNodeEditor", "build/bin/" .. outputdir .. "/ImGuiNodeEditor",
"build/bin/" .. outputdir .. "/SDL3" "build/bin/" .. outputdir .. "/SDL3",
"build/bin/" .. outputdir .. "/spdlog"
} }
links{ links{
"ImGui", "ImGui",
"ImGuiNodeEditor", "ImGuiNodeEditor",
"SDL3" "SDL3",
"spdlog"
} }
filter "system:windows" filter "system:windows"
@@ -114,7 +124,6 @@ project "SakuraVNE" --project under solution
-- TELL THE LINKER TO USE SYSTEM LIBS -- TELL THE LINKER TO USE SYSTEM LIBS
links { links {
--"GL", -- OpenGL is usually required for ImGui/SDL apps
"dl", -- Dynamic linking loader (often needed) "dl", -- Dynamic linking loader (often needed)
"pthread" -- POSIX threads (often needed) "pthread" -- POSIX threads (often needed)
} }