diff options
| author | ruki <[email protected]> | 2019-03-07 00:40:17 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2019-03-06 22:01:46 +0800 |
| commit | 9830bb8528f8adea2ee865cdba27e7b1fe81920c (patch) | |
| tree | c4ad076d94e968e83783b060ac193495c9a6bf84 /xmake/modules | |
| parent | 9dbd51e4ce52f79d2379e8d0f7dbf5e7784add2f (diff) | |
support vs2019 preview
Diffstat (limited to 'xmake/modules')
| -rwxr-xr-x[-rw-r--r--] | xmake/modules/detect/sdks/find_vstudio.lua | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/xmake/modules/detect/sdks/find_vstudio.lua b/xmake/modules/detect/sdks/find_vstudio.lua index ece424d97..f9b50fa1f 100644..100755 --- a/xmake/modules/detect/sdks/find_vstudio.lua +++ b/xmake/modules/detect/sdks/find_vstudio.lua @@ -128,7 +128,8 @@ function main(opt) -- init vsvers local vsvers = { - ["15.0"] = "2017" + ["16.0"] = "2019" + , ["15.0"] = "2017" , ["14.0"] = "2015" , ["12.0"] = "2013" , ["11.0"] = "2012" @@ -247,6 +248,16 @@ function main(opt) if vswhere_VCAuxiliaryBuildDir and os.isdir(vswhere_VCAuxiliaryBuildDir) then table.insert(pathes, vswhere_VCAuxiliaryBuildDir) end + + -- find vs from some logical drives pathes + for _, logical_drive in ipairs(winos.logical_drives()) do + if os.isdir(path.join(logical_drive, "Program Files (x86)")) then + table.insert(pathes, path.join(logical_drive, "Program Files (x86)", "Microsoft Visual Studio", vsvers[version], "*", "VC", "Auxiliary", "Build")) + table.insert(pathes, path.join(logical_drive, "Program Files (x86)", "Microsoft Visual Studio " .. version, "VC")) + end + table.insert(pathes, path.join(logical_drive, "Program Files", "Microsoft Visual Studio", vsvers[version], "*", "VC", "Auxiliary", "Build")) + table.insert(pathes, path.join(logical_drive, "Program Files", "Microsoft Visual Studio " .. version, "VC")) + end -- find vcvarsall.bat, vcvars32.bat for vs7.1 local vcvarsall = find_file("vcvarsall.bat", pathes) or find_file("vcvars32.bat", pathes) |
