summaryrefslogtreecommitdiff
path: root/xmake/scripts/linker/_ar.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2015-06-02 09:35:37 +0800
committerruki <[email protected]>2015-06-02 09:35:37 +0800
commitf6177ffb405aa474e5d8e8af787778bd8ed8439c (patch)
treec4520100c7b617a4ef54f137f2f8acb13d98f5ab /xmake/scripts/linker/_ar.lua
parent52b7de2f4d73e08aba2fea79aa04bb06a9af449d (diff)
add linker and compiler common flags
Diffstat (limited to 'xmake/scripts/linker/_ar.lua')
-rw-r--r--xmake/scripts/linker/_ar.lua9
1 files changed, 6 insertions, 3 deletions
diff --git a/xmake/scripts/linker/_ar.lua b/xmake/scripts/linker/_ar.lua
index 39aeadc56..c65fa41f2 100644
--- a/xmake/scripts/linker/_ar.lua
+++ b/xmake/scripts/linker/_ar.lua
@@ -31,13 +31,16 @@ local config = require("base/config")
-- init the linker
function _ar._init(configs)
+ -- init arflags
+ configs.arflags = "-crs"
+
end
--- make the static library command
-function _ar._make_static(configs, objfiles, targetfile, flags)
+-- make the command
+function _ar._make(configs, objfiles, targetfile, flags)
-- make it
- return string.format("%s -crs %s %s %s", configs.name, flags, targetfile, table.concat(objfiles))
+ return string.format("%s %s %s %s", configs.name, flags, targetfile, objfiles)
end
-- map gcc flag to the current linker flag