diff options
| author | ruki <[email protected]> | 2017-02-25 20:54:38 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2017-02-25 20:54:38 +0800 |
| commit | d2cb65ef196d9c9696136040b66cd3b8efde3133 (patch) | |
| tree | 18537bdaca0c12187981d3b5ad2dd7d38f751441 /xmake/tools | |
| parent | 7594c6a140173ce5ca2475587b86bc865d183ea0 (diff) | |
rename goflags to gcflags
Diffstat (limited to 'xmake/tools')
| -rwxr-xr-x | xmake/tools/go.lua | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/xmake/tools/go.lua b/xmake/tools/go.lua index a8966404f..4d25792a3 100755 --- a/xmake/tools/go.lua +++ b/xmake/tools/go.lua @@ -58,6 +58,52 @@ function get(name) return _g[name] end +-- make the optimize flag +function nf_optimize(level) + + -- the maps + local maps = + { + none = "-N" + , fast = "" + , faster = "" + , fastest = "" + , smallest = "" + , aggressive = "" + } + + -- make it + return maps[level] or "" +end + +-- make the symbol flag +function nf_symbol(level) + + -- the maps + local maps = + { + debug = "-E" + , hidden = "" + } + + -- make it + return maps[level] or "" +end + +-- make the strip flag +function nf_strip(level) + + -- the maps + local maps = + { + debug = "-s" + , all = "-s" + } + + -- make it + return maps[level] or "" +end + -- make the includedir flag function nf_includedir(dir) |
