XMake: Improve natvis rules
This commit is contained in:
parent
5a14808a57
commit
da49b39465
|
|
@ -1,12 +1,12 @@
|
|||
rule("natvis")
|
||||
on_config(function (target)
|
||||
for name, pkg in pairs(target:pkgs()) do
|
||||
for name, pkg in table.orderpairs(target:pkgs()) do
|
||||
local includedir = path.join(pkg:installdir(), "include")
|
||||
local natvis = os.files(path.join(includedir, "**.natvis"))
|
||||
if #natvis > 0 then
|
||||
local groups = table.wrap(target:get("filegroups"))
|
||||
if not table.find(groups, name) then
|
||||
target:add("headerfiles", natvis, { install = false })
|
||||
target:add("extrafiles", natvis)
|
||||
target:add("filegroups", path.join("nativs", name), { rootdir = includedir })
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue