summaryrefslogtreecommitdiff
path: root/xmake/plugins/project/main.lua
diff options
context:
space:
mode:
authorOpportunityLiu <[email protected]>2019-07-18 19:50:02 +0800
committerOpportunityLiu <[email protected]>2019-07-19 11:48:33 +0800
commite765aa75b91f847e93893271abe1cf265126da54 (patch)
treeb30511a741672d712d43fb419499fcf30e80de37 /xmake/plugins/project/main.lua
parenta8cc8e8989fd52574088200c5d6bbc3a4582d911 (diff)
cleanup code
Diffstat (limited to 'xmake/plugins/project/main.lua')
-rwxr-xr-xxmake/plugins/project/main.lua33
1 files changed, 8 insertions, 25 deletions
diff --git a/xmake/plugins/project/main.lua b/xmake/plugins/project/main.lua
index ede6989fb..cfcf10c2b 100755
--- a/xmake/plugins/project/main.lua
+++ b/xmake/plugins/project/main.lua
@@ -26,27 +26,10 @@ import("core.platform.environment")
import("make.makefile")
import("cmake.cmakelists")
import("vstudio.vs")
-import("vstudio.vsx")
import("vsxmake.vsxmake")
import("clang.compile_flags")
import("clang.compile_commands")
-function _vs(outputdir)
- local vsver = assert(tonumber(config.get("vs")), "invalid vs version, run `xmake f --vs=2015`")
- vprint("using project kind vs%d", vsver)
- if vsver < 2010 then
- return vs.make(vsver)(outputdir)
- else
- return vsx.make(vsver)(outputdir)
- end
-end
-
-function _vsxmake(outputdir)
- local vsver = assert(tonumber(config.get("vs")), "invalid vs version, run `xmake f --vs=2015`")
- vprint("using project kind vsxmake%d", vsver)
- return vsxmake.make(vsver)(outputdir)
-end
-
-- make project
function _make(kind)
@@ -59,20 +42,20 @@ function _make(kind)
, vs2003 = vs.make(2003)
, vs2005 = vs.make(2005)
, vs2008 = vs.make(2008)
- , vs2010 = vsx.make(2010)
- , vs2012 = vsx.make(2012)
- , vs2013 = vsx.make(2013)
- , vs2015 = vsx.make(2015)
- , vs2017 = vsx.make(2017)
- , vs2019 = vsx.make(2019)
- , vs = _vs
+ , vs2010 = vs.make(2010)
+ , vs2012 = vs.make(2012)
+ , vs2013 = vs.make(2013)
+ , vs2015 = vs.make(2015)
+ , vs2017 = vs.make(2017)
+ , vs2019 = vs.make(2019)
+ , vs = vs.make()
, vsxmake2010 = vsxmake.make(2010)
, vsxmake2012 = vsxmake.make(2012)
, vsxmake2013 = vsxmake.make(2013)
, vsxmake2015 = vsxmake.make(2015)
, vsxmake2017 = vsxmake.make(2017)
, vsxmake2019 = vsxmake.make(2019)
- , vsxmake = _vsxmake
+ , vsxmake = vsxmake.make()
, compile_flags = compile_flags.make
, compile_commands = compile_commands.make
}