mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-22 02:38:11 +00:00
22 lines
522 B
Bash
Executable File
22 lines
522 B
Bash
Executable File
#!/bin/sh
|
|
|
|
if [ -z "$EMSCRIPTEN" ] ; then
|
|
echo "run this script with emmake. Ex: emmake $0"
|
|
exit 1
|
|
fi
|
|
|
|
make -C ../ -f Makefile.emscripten clean || exit 1
|
|
|
|
for f in *_emscripten.bc ; do
|
|
name=`echo "$f" | sed 's/\(_libretro_emscripten\|\).bc$//'`
|
|
lto=0
|
|
echo "building $name"
|
|
if [ $name = "tyrquake" ] ; then
|
|
lto=0
|
|
fi
|
|
cp -f "$f" ../libretro_emscripten.bc
|
|
make -C ../ -f Makefile.emscripten LTO=$lto -j7 || exit 1
|
|
cp -fv ../retroarch.js ../emscripten/$name.js
|
|
rm -f ../retroarch.js
|
|
done
|