More build script fies (lua compiler)

master
Icedream 2014-10-20 12:43:48 +02:00
parent 25f9767509
commit 736318a730
1 changed files with 6 additions and 4 deletions

View File

@ -77,11 +77,13 @@ mkdir -p ../tmp/lua
find . -type f -name '*.lua' | while read absfile; do find . -type f -name '*.lua' | while read absfile; do
file="lua/$absfile" file="lua/$absfile"
echo "Compiling $file..." echo "Compiling $file..."
luac52 -o "../tmp/$file" "$absfile" || ( luac52 -o "../tmp/$file.luac" "$absfile" && (
echo "Could not compile $file, only copying..." rm "/tmp/$file"
cp "$absfile" "../tmp/$file" mv "/tmp/$file.luac" "/tmp/$file"
) || (
echo "Could not compile $file, leaving as is."
) )
) done
popd popd
# Create the GMA file # Create the GMA file