extras/buildbot-emscripten.sh
branchstable-3.0
changeset 1688 62804a972e79
parent 1677 f17e8358de41
equal deleted inserted replaced
1681:1e79b94d7c57 1688:62804a972e79
     1 #!/bin/bash
     1 #!/bin/bash
     2 
     2 
     3 if [ -z "$SDKDIR" ]; then
     3 if [ -z "$SDKDIR" ]; then
     4     SDKDIR="/emsdk_portable"
     4     SDKDIR="/emsdk"
     5 fi
     5 fi
     6 
     6 
     7 ENVSCRIPT="$SDKDIR/emsdk_env.sh"
     7 ENVSCRIPT="$SDKDIR/emsdk_env.sh"
     8 if [ ! -f "$ENVSCRIPT" ]; then
     8 if [ ! -f "$ENVSCRIPT" ]; then
     9    echo "ERROR: This script expects the Emscripten SDK to be in '$SDKDIR'." 1>&2
     9    echo "ERROR: This script expects the Emscripten SDK to be in '$SDKDIR'." 1>&2
    31 
    31 
    32 echo "Configuring..."
    32 echo "Configuring..."
    33 emcmake cmake -G "Ninja" -DPHYSFS_BUILD_SHARED=False -DCMAKE_BUILD_TYPE=MinSizeRel .. || exit $?
    33 emcmake cmake -G "Ninja" -DPHYSFS_BUILD_SHARED=False -DCMAKE_BUILD_TYPE=MinSizeRel .. || exit $?
    34 
    34 
    35 echo "Building..."
    35 echo "Building..."
    36 emcmake cmake --build . --config MinSizeRel || exit $?
    36 emmake cmake --build . --config MinSizeRel || exit $?
    37 
    37 
    38 set -e
    38 set -e
    39 rm -rf "$TARBALL" physfs-emscripten
    39 rm -rf "$TARBALL" physfs-emscripten
    40 mkdir -p physfs-emscripten
    40 mkdir -p physfs-emscripten
    41 echo "Archiving to '$TARBALL' ..."
    41 echo "Archiving to '$TARBALL' ..."