From 6462dc364ff59b2be8d7e2e746aea8ab8340e72f Mon Sep 17 00:00:00 2001 From: mpeterv Date: Mon, 26 Oct 2015 23:15:33 +0300 Subject: [PATCH] Use install.bat for LuaRocks on Windows --- hererocks.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/hererocks.py b/hererocks.py index b724cf5..98d6d83 100755 --- a/hererocks.py +++ b/hererocks.py @@ -444,12 +444,16 @@ def install_luarocks(target_dir, luarocks_version, verbose, temp_dir): if not os.path.exists(target_dir): os.makedirs(target_dir) - print("Building LuaRocks") - run_command(verbose, "./configure", "--prefix=" + quote(target_dir), - "--with-lua=" + quote(target_dir), "--force-config") - run_command(verbose, "make build") print("Installing LuaRocks") - run_command(verbose, "make install") + + if get_lua_target() == "mingw": + run_command(verbose, "install.bat", "/Q", "/LUA", quote(target_dir), + "/P", quote(target_dir), "/SELFCONTAINED", "/FORCECONFIG", "/MW") + else: + run_command(verbose, "./configure", "--prefix=" + quote(target_dir), + "--with-lua=" + quote(target_dir), "--force-config") + run_command(verbose, "make build") + run_command(verbose, "make install") def main(): parser = argparse.ArgumentParser(