aboutsummaryrefslogtreecommitdiffstats
path: root/ltg.sh
diff options
context:
space:
mode:
Diffstat (limited to 'ltg.sh')
-rwxr-xr-xltg.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/ltg.sh b/ltg.sh
new file mode 100755
index 0000000..dc1e37c
--- /dev/null
+++ b/ltg.sh
@@ -0,0 +1,12 @@
+#!/usr/bin/bash
+cd $(dirname $0)
+if [[ -d ./out ]]; then :;else mkdir ./out;fi
+./luatablegen/luatablegen.py --out ./out --luaheader ../test/lua --headeraggr ./out/wasm_tables.h --lualibpath ./out/wasm.lua --docpath ./out/wasm.md --xml ./luatablegen/test/luwasm.xml --tbldefs ./out/ --anon --name wasm --lualibname wasmextra
+clang-format ./out/*.c ./out/*.h -i
+for filename in ./out/*.c; do
+ gcc -c $filename > /dev/null 2>&1
+ if [[ $? != 0 ]]; then
+ echo $filename did not compile.
+ fi
+done
+rm *.o