-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathecs-project.lua
More file actions
39 lines (31 loc) · 1.19 KB
/
Copy pathecs-project.lua
File metadata and controls
39 lines (31 loc) · 1.19 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
-- Reusable ECS project definition
-- Can be included by parent projects via: include("path/to/ecs-lib/ecs-project.lua")
-- This will also include the Log project dependency (if not already included)
local ecs_lib_dir = path.getdirectory(_SCRIPT)
local ecs_lib_src = ecs_lib_dir .. "/ecs-lib"
local log_lib_dir = ecs_lib_dir .. "/dep/log-lib"
-- Only include log-lib if not already included by parent project
if not LOG_LIB_INCLUDED then
include(log_lib_dir .. "/log-project.lua")
end
-- Use exported path from log-lib if available, otherwise use local path
local log_include_dir = LOG_LIB_INCLUDE_DIR or (log_lib_dir .. "/log-lib/include")
project("ECS")
kind("StaticLib")
language("C++")
cppdialect("C++23")
objdir("obj/%{prj.name}/%{cfg.buildcfg}")
targetdir("bin/%{prj.name}/%{cfg.buildcfg}")
files({
ecs_lib_src .. "/src/**.cpp",
ecs_lib_src .. "/src/**.h",
ecs_lib_src .. "/include/**.h"
})
includedirs({
log_include_dir,
ecs_lib_src .. "/include",
ecs_lib_src .. "/src"
})
links({ "Log" })
pchheader(path.getabsolute(ecs_lib_src .. "/src/general/pch.h"))
pchsource(ecs_lib_src .. "/src/general/pch.cpp")