-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathproject_lib_tool.lua
More file actions
45 lines (33 loc) · 977 Bytes
/
project_lib_tool.lua
File metadata and controls
45 lines (33 loc) · 977 Bytes
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
--
-- Zidar - Build system scripts
-- Copyright (c) 2025-2026 Milos Tosic, Rudji Games. All rights reserved.
-- License: https://github.com/RudjiGames/zidar/blob/master/LICENSE
--
function addProject_lib_tool(_name, _libName)
group ( "libs-tools" )
project ( _name .. "_" .. _libName )
project().kind = "ConsoleApp"
kind ( project().kind )
uuid ( os.uuid(project().name) )
flags { Flags_Libraries }
local projectPath = projectGetPath(project().name)
local sourceFiles = projectSourceFilesWildcard(projectPath)
files { sourceFiles }
if projectIsCPP(sourceFiles) then
language "C++"
else
language "C"
end
includedirs
{
projectPath .. "/src",
projectPath .. "/tools" .. "/" .. _name,
}
addPCH( projectPath, project().name )
local dependencies = { _name }
if projectRequiresBGFX( projectPath ) then
dependencies[#dependencies + 1] = "bgfx"
end
projectConfig()
addDependencies(project().name, dependencies)
end