Skip to content

Commit 4886b81

Browse files
committed
Fix warning
1 parent 3b69a10 commit 4886b81

2 files changed

Lines changed: 3 additions & 7 deletions

File tree

tests/xmake.lua

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,4 @@ target("CppUtils-UnitTests", function()
33
add_deps("CppUtils")
44
add_files("**.cpp")
55
add_files("**.mpp", { public = true })
6-
7-
if is_plat("linux") then
8-
add_packages("wayland", "wayland-protocols")
9-
add_rules("wayland.protocols")
10-
end
116
end)

xmake/rules/wayland-protocols.lua

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ do
2828
for _, protocol in ipairs(protocols) do
2929
local full = path.join(wayland_protocols_dir, protocol[1])
3030
if os.exists(full) then
31-
target:add("files", full, { rule = "wayland.protocols" })
31+
target:add("files", full)
3232
else
3333
print("Protocol not found: " .. protocol[1])
3434
end
@@ -61,12 +61,13 @@ do
6161
end
6262

6363
-- Ajout explicitement le fichier source pour garantir son inclusion
64+
-- always_added = true est nécessaire car le fichier est généré pendant le build
6465
target:add("files", source, { always_added = true })
6566
end
6667
end
6768

6869
-- Rend accessible les fichiers générés depuis le projet utilisant cette rule
69-
target:add("includedirs", outputDirectory, { public = true }) -- todo: retirer le public ?
70+
target:add("includedirs", outputDirectory, { public = true })
7071
end)
7172

7273
before_buildcmd_file(function(target, batchcmds, sourcefile, opt) -- sourcefile est un fichier XML

0 commit comments

Comments
 (0)