diff options
| author | ruki <[email protected]> | 2021-09-01 13:52:18 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2021-09-01 13:52:18 +0800 |
| commit | 671cabb77b5421fae4fabecdfe9d0df4adf0ddb8 (patch) | |
| tree | 4c7931944667534e5e5bf009b02d46f5f8383e6f | |
| parent | 6b10c3a9380131639bbf183d78491f6fc0f20535 (diff) | |
Update clang.lua
| -rw-r--r-- | xmake/modules/core/tools/clang.lua | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/xmake/modules/core/tools/clang.lua b/xmake/modules/core/tools/clang.lua index a0d39f3b4..e5734a953 100644 --- a/xmake/modules/core/tools/clang.lua +++ b/xmake/modules/core/tools/clang.lua @@ -124,3 +124,16 @@ function nf_warning(self, level) } return maps[level] end + +-- make the symbol flag +function nf_symbol(self, level) + local kind = self:kind() + if kind == "ld" or kind == "sh" then + -- clang/windows need add `-g` to linker to generate pdb symbol file + if self:plat() == "windows" and level == "debug" then + return "-g" + end + else + return _super.nf_symbol(self, level) + end +end |
