summaryrefslogtreecommitdiff
path: root/dev-lang/luajit/files/luac.jit
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lang/luajit/files/luac.jit')
-rw-r--r--dev-lang/luajit/files/luac.jit32
1 files changed, 32 insertions, 0 deletions
diff --git a/dev-lang/luajit/files/luac.jit b/dev-lang/luajit/files/luac.jit
new file mode 100644
index 0000000..2f70064
--- /dev/null
+++ b/dev-lang/luajit/files/luac.jit
@@ -0,0 +1,32 @@
+#!/usr/bin/env sh
+help() {
+ echo "This binary is only wrapper for LuaJIT-not-ready software"
+ echo "You should use 'luajit -b' if you want to compile bytecode manually."
+ exit 0;
+}
+
+out="luac.out"
+i=1;
+if [[ ${#} = 0 ]]; then help; fi
+for args in "${@}"; do
+case $args in
+ -o)
+ shift ${i}
+ out="${1}"
+ shift 1
+ i=0
+ ;;
+ -v)
+ luajit -v
+ exit 0;
+ ;;
+ -p)
+ out="/dev/null"
+ ;;
+ --help)
+ help
+ ;;
+esac
+let i=${i}+1
+done;
+luajit -b "${@}" "${out}"