Browse Source

Update build process utilities to work with Lua 5.2 in up-to-date Premake.

pull/838/merge
Joao Matos 8 years ago
parent
commit
bd2b22c580
  1. 9
      build/scripts/Utils.lua

9
build/scripts/Utils.lua

@ -19,14 +19,13 @@ end @@ -19,14 +19,13 @@ end
function execute(cmd, quiet)
print(cmd)
if not quiet then
return os.execute(cmd)
local status, exit, err = os.execute(cmd)
return err
else
local file = assert(io.popen(cmd .. " 2>&1", "r"))
local output = file:read('*all')
file:close()
-- FIXME: Lua 5.2 returns the process exit code from close()
-- Update this once Premake upgrades from Lua 5.1
return 0
local status, exit, err = file:close()
return err
end
end

Loading…
Cancel
Save