diff options
| author | Saikari <[email protected]> | 2026-01-30 20:42:57 +0300 |
|---|---|---|
| committer | Saikari <[email protected]> | 2026-01-30 20:42:57 +0300 |
| commit | b006af493bff65fcffd198db70ec2c8046f6575e (patch) | |
| tree | 6e40e74d2a966cc40160c713f3947f5edb5d2620 /xmake/plugins | |
| parent | 51a68ee33918b95811420beb6a56673a83abe6cc (diff) | |
enhance compile_commands support and add test cases
Diffstat (limited to 'xmake/plugins')
| -rw-r--r-- | xmake/plugins/project/clang/compile_commands.lua | 5 |
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..28f4a876b 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("build.compile_commands") == false then + return + end + -- enter package environments local oldenvs = os.addenvs(target:pkgenvs()) |
