summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/modules/detect/sdks/find_vstudio.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/xmake/modules/detect/sdks/find_vstudio.lua b/xmake/modules/detect/sdks/find_vstudio.lua
index 69d8613b7..41c019439 100644
--- a/xmake/modules/detect/sdks/find_vstudio.lua
+++ b/xmake/modules/detect/sdks/find_vstudio.lua
@@ -19,6 +19,7 @@
--
-- imports
+import("core.base.option")
import("core.project.config")
import("lib.detect.find_file")
import("lib.detect.find_tool")
@@ -154,8 +155,8 @@ function _load_vcvarsall(vcvarsall, vsver, arch, opt)
-- run genvcvars.bat
local outdata, errdata = try {function () return os.iorun(genvcvars_bat) end}
- if errdata then
- wprint("get vcvars error: %s", errdata)
+ if errdata and option.get("verbose") and option.get("diagnosis") then
+ cprint("${color.warning}checkinfo: ${clear dim}get vcvars error: %s", errdata)
end
if not outdata then
return