diff options
Diffstat (limited to 'lib/genloadlib.sh')
| -rwxr-xr-x | lib/genloadlib.sh | 13 | 
1 files changed, 13 insertions, 0 deletions
| diff --git a/lib/genloadlib.sh b/lib/genloadlib.sh new file mode 100755 index 0000000..f3b8259 --- /dev/null +++ b/lib/genloadlib.sh @@ -0,0 +1,13 @@ +#!/bin/sh + +ls *.lua | while read f ; do +    b=${f%%.*} +    echo "extern unsigned int size_$b;" +    echo "extern unsigned char $b[];" +    echo +    echo "    Buffer ${b}_buff;" +    echo "    ${b}_buff.write($b, size_$b);" +    echo "    L->load(&${b}_buff);" +    echo +    echo +done | 
