diff options
| author | ruki <[email protected]> | 2015-12-04 11:49:37 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2015-12-04 11:49:37 +0800 |
| commit | 6ece8be70e5141a69720f28e4f18b20664142ae3 (patch) | |
| tree | 9ae6301f68ecec013c6023a2b6d74bd702685f7a /xmake/scripts/platform/windows | |
| parent | 7624723775b58c1811287465e6d7c27cede81b31 (diff) | |
support add_files *.a using ar
Diffstat (limited to 'xmake/scripts/platform/windows')
| -rw-r--r-- | xmake/scripts/platform/windows/tools/cl.lua | 4 | ||||
| -rw-r--r-- | xmake/scripts/platform/windows/tools/link.lua | 6 | ||||
| -rw-r--r-- | xmake/scripts/platform/windows/tools/ml.lua | 4 | ||||
| -rw-r--r-- | xmake/scripts/platform/windows/tools/nmake.lua | 6 |
4 files changed, 10 insertions, 10 deletions
diff --git a/xmake/scripts/platform/windows/tools/cl.lua b/xmake/scripts/platform/windows/tools/cl.lua index fa961273b..ac91273b1 100644 --- a/xmake/scripts/platform/windows/tools/cl.lua +++ b/xmake/scripts/platform/windows/tools/cl.lua @@ -33,7 +33,7 @@ local platform = require("platform/platform") function cl.init(self, name) -- save name - self._NAME = name or "cl.exe" + self.name = name or "cl.exe" -- init cxflags self.cxflags = { "-nologo", "-Gd", "-MP4", "-D_MBCS", "-D_CRT_SECURE_NO_WARNINGS"} @@ -90,7 +90,7 @@ function cl.command_compile(self, srcfile, objfile, flags, logfile) if logfile then redirect = string.format(" > %s 2>&1", logfile) end -- make it - return string.format("%s -c %s -Fo%s %s%s", self._NAME, flags, objfile, srcfile, redirect) + return string.format("%s -c %s -Fo%s %s%s", self.name, flags, objfile, srcfile, redirect) end -- make the define flag diff --git a/xmake/scripts/platform/windows/tools/link.lua b/xmake/scripts/platform/windows/tools/link.lua index 84df08694..b1fda427a 100644 --- a/xmake/scripts/platform/windows/tools/link.lua +++ b/xmake/scripts/platform/windows/tools/link.lua @@ -33,7 +33,7 @@ local platform = require("platform/platform") function link.init(self, name) -- save name - self._NAME = name or "link.exe" + self.name = name or "link.exe" -- the architecture local arch = config.get("arch") @@ -79,11 +79,11 @@ function link.command_link(self, objfiles, targetfile, flags, logfile) if logfile then redirect = string.format(" > %s 2>&1", logfile) end -- make it - local cmd = string.format("%s %s -out:%s %s%s", self._NAME, flags, targetfile, objfiles, redirect) + local cmd = string.format("%s %s -out:%s %s%s", self.name, flags, targetfile, objfiles, redirect) -- too long? if #cmd > 256 then - cmd = string.format("%s%s @<<\n%s -out:%s %s\n<<", self._NAME, redirect, flags, targetfile, objfiles) + cmd = string.format("%s%s @<<\n%s -out:%s %s\n<<", self.name, redirect, flags, targetfile, objfiles) end -- ok? diff --git a/xmake/scripts/platform/windows/tools/ml.lua b/xmake/scripts/platform/windows/tools/ml.lua index c2ea9b9ab..5a6034320 100644 --- a/xmake/scripts/platform/windows/tools/ml.lua +++ b/xmake/scripts/platform/windows/tools/ml.lua @@ -33,7 +33,7 @@ local platform = require("platform/platform") function ml.init(self, name) -- save name - self._NAME = name or "ml.exe" + self.name = name or "ml.exe" -- init asflags self.asflags = { "-nologo", "-Gd", "-MP4", "-D_MBCS", "-D_CRT_SECURE_NO_WARNINGS"} @@ -84,7 +84,7 @@ function ml.command_compile(self, srcfile, objfile, flags, logfile) if logfile then redirect = string.format(" > %s 2>&1", logfile) end -- make it - return string.format("%s -c %s -Fo%s %s%s", self._NAME, flags, objfile, srcfile, redirect) + return string.format("%s -c %s -Fo%s %s%s", self.name, flags, objfile, srcfile, redirect) end -- make the define flag diff --git a/xmake/scripts/platform/windows/tools/nmake.lua b/xmake/scripts/platform/windows/tools/nmake.lua index 0ba2e32e3..3dddc7cf2 100644 --- a/xmake/scripts/platform/windows/tools/nmake.lua +++ b/xmake/scripts/platform/windows/tools/nmake.lua @@ -35,7 +35,7 @@ local nmake = nmake or {} function nmake.init(self, name) -- save name - self._NAME = name or "nmake.exe" + self.name = name or "nmake.exe" -- is verbose? self._VERBOSE = utils.ifelse(xmake._OPTIONS.verbose, "-v", "") @@ -55,9 +55,9 @@ function nmake.main(self, mkfile, target) -- make command local cmd = nil if mkfile and os.isfile(mkfile) then - cmd = string.format("%s /nologo /f %s %s VERBOSE=%s", self._NAME, mkfile, target or "", self._VERBOSE) + cmd = string.format("%s /nologo /f %s %s VERBOSE=%s", self.name, mkfile, target or "", self._VERBOSE) else - cmd = string.format("%s /nologo %s VERBOSE=%s", self._NAME, target or "", self._VERBOSE) + cmd = string.format("%s /nologo %s VERBOSE=%s", self.name, target or "", self._VERBOSE) end -- done |
