From d344f08a54cc31a6f3d42b3966ec31526261cc4f Mon Sep 17 00:00:00 2001 From: James Roseborough Date: Fri, 13 Aug 2010 20:28:11 +0000 Subject: [PATCH] Allow use of lua2java from command line --- src/jse/lua.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/jse/lua.java b/src/jse/lua.java index bd585a0a..dfbc9573 100644 --- a/src/jse/lua.java +++ b/src/jse/lua.java @@ -33,6 +33,7 @@ import org.luaj.vm2.LuaFunction; import org.luaj.vm2.LuaTable; import org.luaj.vm2.LuaValue; import org.luaj.vm2.lib.jse.JsePlatform; +import org.luaj.vm2.lua2java.Lua2Java; import org.luaj.vm2.luajc.LuaJC; @@ -49,7 +50,8 @@ public class lua { " -l name require library 'name'\n" + " -i enter interactive mode after executing 'script'\n" + " -v show version information\n" + - " -j compile into java bytecode\n" + + " -j use lua2java source-to-source compiler\n" + + " -b use luajc bytecode-to-bytecode compiler (requires bcel on class path)\n" + " -- stop handling options\n" + " - execute stdin and stop handling options"; @@ -85,6 +87,9 @@ public class lua { usageExit(); // input script - defer to last stage break; + case 'b': + Lua2Java.install(); + break; case 'j': LuaJC.install(); break;