diff options
| author | ruki <[email protected]> | 2015-06-16 18:27:00 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2015-06-16 18:27:00 +0800 |
| commit | d549aaedf96e6d6eb77e9d588dc0a0269cd1ae71 (patch) | |
| tree | 51d971fe326561b62895743a38a1544af6df2dff /xmake/scripts/tools/ar.lua | |
| parent | 608602d0de1056f856e0b6bfe33b3f5fbe641b63 (diff) | |
fix the command is too long for nmake
Diffstat (limited to 'xmake/scripts/tools/ar.lua')
| -rw-r--r-- | xmake/scripts/tools/ar.lua | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/xmake/scripts/tools/ar.lua b/xmake/scripts/tools/ar.lua index b2e2618eb..b80dc4ddf 100644 --- a/xmake/scripts/tools/ar.lua +++ b/xmake/scripts/tools/ar.lua @@ -40,10 +40,14 @@ function ar.init(self, name) end -- make the link command -function ar.command_link(self, objfiles, targetfile, flags) +function ar.command_link(self, objfiles, targetfile, flags, logfile) + + -- redirect + local redirect = "" + if logfile then redirect = string.format(" > %s 2>&1", logfile) end -- make it - return string.format("%s %s %s %s", self._NAME, flags, targetfile, objfiles) + return string.format("%s %s %s %s%s", self._NAME, flags, targetfile, objfiles, redirect) end -- the main function |
