diff options
| author | ruki <[email protected]> | 2020-04-03 22:58:47 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-04-03 14:20:20 +0800 |
| commit | 9783d272988b51843869af98e0c53fa00cf9c902 (patch) | |
| tree | c81161d9b550a990683e30c6cdf98095abb3e581 /xmake/modules/core/tools/gcc.lua | |
| parent | ed6edd27c52358307e318781f43088adc4dfbdb8 (diff) | |
improve nf_symbol
Diffstat (limited to 'xmake/modules/core/tools/gcc.lua')
| -rw-r--r-- | xmake/modules/core/tools/gcc.lua | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/xmake/modules/core/tools/gcc.lua b/xmake/modules/core/tools/gcc.lua index 5d493ece7..d64a7b5c8 100644 --- a/xmake/modules/core/tools/gcc.lua +++ b/xmake/modules/core/tools/gcc.lua @@ -89,12 +89,15 @@ end -- make the symbol flag function nf_symbol(self, level) - local maps = - { - debug = "-g" - , hidden = "-fvisibility=hidden -fvisibility-inlines-hidden" - } - return maps[level] + -- only for source kind + if language.sourcekinds()[self:kind()] then + local maps = + { + debug = "-g" + , hidden = "-fvisibility=hidden -fvisibility-inlines-hidden" + } + return maps[level] + end end -- make the warning flag |
