-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpremake5.lua
More file actions
76 lines (62 loc) · 2.17 KB
/
premake5.lua
File metadata and controls
76 lines (62 loc) · 2.17 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
require "vendor/export-compile-commands"
-- Define the workspace
workspace "FluidSimulation"
architecture "x64" -- x86_64 architecture
configurations { "Debug", "Release" }
startproject "FluidSim"
-- Output directory format
outputdir = "%{cfg.buildcfg}-%{cfg.system}-%{cfg.architecture}"
-- Define the main project
project "FluidSim"
kind "ConsoleApp" -- Console application
language "C++"
cppdialect "C++17" -- C++17 standard
-- Output directories
targetdir ("bin/" .. outputdir .. "/%{prj.name}")
objdir ("bin-int/" .. outputdir .. "/%{prj.name}")
-- Source files
files {
"src/**.cpp",
"src/**.hpp", -- All .cpp files in src/
"include/**.hpp", -- All .h files in include/ for IDE visibility
"vendor/**.h",
"vendor/**.cpp"
}
-- Include directories
includedirs {
"include", -- Project headers (core/, renderer/)
"vendor",
}
-- Link system-installed libraries (e.g., GLFW, OpenGL, GLEW)
filter "system:linux"
links {
"vulkan",
"glfw", -- GLFW
}
defines { "PLATFORM_LINUX" }
filter "system:windows"
links {
"vulkan-1", -- vulkan-1.lib
"glfw3", -- glfw3.lib
"Triton"
}
defines { "PLATFORM_WINDOWS" }
-- Vulkan SDK include and library paths (using VULKAN_SDK environment variable)
includedirs {
"C:/VulkanSDK/1.4.304.0/Include",
"C:/glfw/glfw-3.4.bin.WIN64/include",
"./Triton/include"
}
libdirs {
"C:/VulkanSDK/1.4.304.0/Lib",
"C:/glfw/glfw-3.4.bin.WIN64/lib-vc2022",
"./Triton/bin/" .. outputdir .. "/Triton"
}
-- Configuration-specific settings
filter "configurations:Debug"
defines { "DEBUG" }
symbols "On" -- Debugging symbols
optimize "Off"
filter "configurations:Release"
defines { "NDEBUG" }
optimize "On"