diff options
| author | ruki <[email protected]> | 2020-05-27 00:50:35 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-05-26 23:03:31 +0800 |
| commit | 7690eaf09fd10101d67c10f8fdbf3fc0f02992fe (patch) | |
| tree | b7efd5d07e96ae89790fff71b26bc491b31aa8e7 /xmake/modules/core/tools/link.lua | |
| parent | 8711cc579bc5519f400e25d09cee8d79f0e454bf (diff) | |
add winos.cmdargv
Diffstat (limited to 'xmake/modules/core/tools/link.lua')
| -rw-r--r-- | xmake/modules/core/tools/link.lua | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/xmake/modules/core/tools/link.lua b/xmake/modules/core/tools/link.lua index ccf679c20..3bcbb238d 100644 --- a/xmake/modules/core/tools/link.lua +++ b/xmake/modules/core/tools/link.lua @@ -92,19 +92,9 @@ end -- make the link arguments list function linkargv(self, objectfiles, targetkind, targetfile, flags, opt) - - -- init arguments - local argv = table.join(flags, "-out:" .. os.args(targetfile), objectfiles) - - -- too long arguments for windows? opt = opt or {} - local args = os.args(argv, {escape = true}) - if #args > 1024 and not opt.rawargs then - local argsfile = os.tmpfile(args) .. ".args.txt" - io.writefile(argsfile, args) - argv = {"@" .. argsfile} - end - return self:program(), argv + local argv = table.join(flags, "-out:" .. targetfile, objectfiles) + return self:program(), opt.rawargs and argv or winos.cmdargv(argv) end -- link the target file |
