From be0535a48070ab2a8f11caf2f034e55262a6b448 Mon Sep 17 00:00:00 2001 From: ruki Date: Wed, 15 Mar 2017 18:23:54 +0800 Subject: add os.run error info --- xmake/core/base/os.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/xmake/core/base/os.lua b/xmake/core/base/os.lua index 9fcae713a..cfbc00611 100644 --- a/xmake/core/base/os.lua +++ b/xmake/core/base/os.lua @@ -444,6 +444,13 @@ function os.runv(shellname, argv) -- make errors local errors = io.readall(log) + if not errors or #errors == 0 then + if argv ~= nil then + errors = string.format("runv(%s %s) failed(%d)!", shellname, table.concat(argv, ' '), ok) + else + errors = string.format("runv(%s) failed(%d)!", shellname, ok) + end + end -- remove the temporary log file os.rm(log) -- cgit v1.3.1