summaryrefslogtreecommitdiff
path: root/build-scripts
diff options
context:
space:
mode:
authorRyan C. Gordon <icculus@icculus.org>2014-12-24 13:03:20 -0500
committerRyan C. Gordon <icculus@icculus.org>2014-12-24 13:03:20 -0500
commitd849777d1270587c1dcb0699bf5ae5087441e4c6 (patch)
treed3e6f81db520966fe95f2bb5d9ac475a9c805976 /build-scripts
parent8399b054df16bf47be6dc44c376916933223342a (diff)
A little more work on the Emscripten buildbot script.
Should upload tarballs now, etc.
Diffstat (limited to 'build-scripts')
-rwxr-xr-xbuild-scripts/emscripten-buildbot.sh20
1 files changed, 15 insertions, 5 deletions
diff --git a/build-scripts/emscripten-buildbot.sh b/build-scripts/emscripten-buildbot.sh
index 90cf9e2a4e..aeef83b445 100755
--- a/build-scripts/emscripten-buildbot.sh
+++ b/build-scripts/emscripten-buildbot.sh
@@ -7,6 +7,11 @@ if [ ! -f "$ENVSCRIPT" ]; then
exit 1
fi
+TARBALL="$1"
+if [ -z $1 ]; then
+ TARBALL=sdl-emscripten.tar.xz
+fi
+
cd `dirname "$0"`
cd ..
SDLBASE=`pwd`
@@ -39,21 +44,26 @@ echo "Setting up Emscripten SDK environment..."
source "$ENVSCRIPT"
echo "Setting up..."
-set -e
set -x
cd "$SDLBASE"
rm -rf buildbot
+rm -rf emscripten-sdl2-installed
mkdir buildbot
-cd buildbot
+pushd buildbot
echo "Configuring..."
-emconfigure ../configure --host=asmjs-unknown-emscripten --disable-assembly --disable-threads --enable-cpuinfo=false CFLAGS="-O2 -Wno-warn-absolute-paths"
+emconfigure ../configure --host=asmjs-unknown-emscripten --disable-assembly --disable-threads --enable-cpuinfo=false CFLAGS="-O2 -Wno-warn-absolute-paths -Wdeclaration-after-statement -Werror=declaration-after-statement" --prefix="$SDLBASE/emscripten-sdl2-installed"
echo "Building..."
emmake $MAKE
-set +x
-echo "Done! The library is in $SDLBASE/buildbot/build/.libs/libSDL2.a ..."
+echo "Moving things around..."
+emmake $MAKE install
+mkdir -p ./usr
+mv "$SDLBASE/emscripten-sdl2-installed" ./usr/local
+popd
+tar -cJvvf $TARBALL -C buildbot usr
+rm -rf buildbot
exit 0