diff options
Diffstat (limited to 'tools/build-pkg.lua')
-rwxr-xr-x | tools/build-pkg.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/build-pkg.lua b/tools/build-pkg.lua index 44a58ba..fdfa577 100755 --- a/tools/build-pkg.lua +++ b/tools/build-pkg.lua @@ -135,6 +135,15 @@ local function shell(cmd) return text end +local function testCommand(cmd) + if _VERSION == 'Lua 5.1' then + return os.execute(cmd) == 0 + else + -- Lua >= 5.2 + return os.execute(cmd) + end +end + local function fileExists(name) local f = io.open(name, "r") if f ~= nil then |