summaryrefslogtreecommitdiff
path: root/xmake/plugins
diff options
context:
space:
mode:
authorSaikari <[email protected]>2026-02-01 12:19:49 +0300
committerGitHub <[email protected]>2026-02-01 12:19:49 +0300
commit9fce99ffc77bdd8c77cb0e3d4c129eaa012246f1 (patch)
treedc636b1925aaa56d81501529b6b2330e6ea6058c /xmake/plugins
parent336fce6edf7a4a2932b8ac0881cd10b2d62d3ecc (diff)
parentd7bdbc99bcc5b64a3fa257c5835014f5d8878150 (diff)
Merge branch 'xmake-io:dev' into stdin
Diffstat (limited to 'xmake/plugins')
-rw-r--r--xmake/plugins/project/clang/compile_commands.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/xmake/plugins/project/clang/compile_commands.lua b/xmake/plugins/project/clang/compile_commands.lua
index 4f01354fa..909184800 100644
--- a/xmake/plugins/project/clang/compile_commands.lua
+++ b/xmake/plugins/project/clang/compile_commands.lua
@@ -266,6 +266,11 @@ function _add_target(jsonfile, target)
-- https://github.com/xmake-io/xmake/issues/2337
target:data_set("plugin.project.kind", "compile_commands")
+ -- disable compile_commands?
+ if target:policy("generator.compile_commands") == false then
+ return
+ end
+
-- enter package environments
local oldenvs = os.addenvs(target:pkgenvs())