29:df7b709d3bbc
Anton Shestakov <av6@dwimlabs.net>, Wed, 20 Jun 2018 17:48:52 +0800
recipe: explain what it is, just in case

next change 30:b02a3ab35cfe
previous change 26:95a37a852387

recipe.sh

Permissions: -rw-r--r--

Other formats: Feeds:
#!/bin/sh
echo "Don't run this script directly, it's not ready for that yet."
echo "Instead, read through it and hand-pick statements that you need."
exit 1
# cd game-music-player
# mkdir build
# cd build
emcmake cmake ../
emmake make gme
# Original, big and inclusive
emcc gme/libgme.so -o libgme.O0.js -s LINKABLE=1 -s EXPORT_ALL=1 -O0
(
echo '['
grep -E 'gme_[a-z0-9_]+' -o player.js | sort -u | awk '{printf " \"_" $0 "\",\n"}' | sed '$s/,$//'
echo ']'
) > exported_functions.json
# Smaller and hand-picked
emcc gme/libgme.so -o libgme.O2.js -s NO_FILESYSTEM=1 -s EXPORTED_FUNCTIONS=@exported_functions.json -O2
# Smaller still
emcc gme/libgme.so -o libgme.Oz.js -s NO_FILESYSTEM=1 -s EXPORTED_FUNCTIONS=@exported_functions.json -Oz --llvm-lto 1