Skip to content

Commit 6ab4fdb

Browse files
committed
chore: use shared as submodule
1 parent 5937778 commit 6ab4fdb

2 files changed

Lines changed: 7 additions & 35 deletions

File tree

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "lib/commonlib-shared"]
2+
path = lib/commonlib-shared
3+
url = https://github.com/libxse/commonlib-shared.git

xmake.lua

Lines changed: 4 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -7,44 +7,13 @@ set_languages("c++23")
77
set_warnings("allextra")
88
set_encodings("utf-8")
99

10-
-- add repositories
11-
add_repositories("libxse-xrepo https://github.com/libxse/libxse-xrepo")
12-
1310
-- add rules
1411
add_rules("mode.debug", "mode.releasedbg")
1512

16-
-- make custom rules available
13+
-- add includes
14+
includes("lib/commonlib-shared")
1715
includes("xmake-rules.lua")
1816

19-
-- define options
20-
option("commonlib_ini", function()
21-
set_default(false)
22-
set_description("enable REX::INI settings support")
23-
end)
24-
25-
option("commonlib_json", function()
26-
set_default(false)
27-
set_description("enable REX::JSON settings support")
28-
end)
29-
30-
option("commonlib_toml", function()
31-
set_default(false)
32-
set_description("enable REX::TOML settings support")
33-
end)
34-
35-
option("commonlib_xbyak", function()
36-
set_default(false)
37-
set_description("enable xbyak support for trampoline")
38-
end)
39-
40-
-- require packages
41-
add_requires("commonlib-shared 7c29a1e16b4ee5d5ee06f706590b28099b7a5a59", { configs = {
42-
ini = has_config("commonlib_ini"),
43-
json = has_config("commonlib_json"),
44-
toml = has_config("commonlib_toml"),
45-
xbyak = has_config("commonlib_xbyak")
46-
} })
47-
4817
-- define targets
4918
target("commonlibf4", function()
5019
-- set target kind
@@ -53,8 +22,8 @@ target("commonlibf4", function()
5322
-- set build by default
5423
set_default(os.scriptdir() == os.projectdir())
5524

56-
-- add packages
57-
add_packages("commonlib-shared", { public = true })
25+
-- add dependencies
26+
add_deps("commonlib-shared", { public = true })
5827

5928
-- add source files
6029
add_files("src/**.cpp")

0 commit comments

Comments
 (0)