Skip to content

Commit ca85c40

Browse files
committed
travis: try to fix the build on emscripten
The emsdk-portable .tar.gz now extracts to emsdk-portable instead of emsdk_portable. Handle that.
1 parent 49c67bd commit ca85c40

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

src/ci/docker/emscripten/build-emscripten.sh

+14-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,20 @@ exit 1
2929
}
3030

3131
curl https://s3.amazonaws.com/mozilla-games/emscripten/releases/emsdk-portable.tar.gz | \
32-
tar xzf -
32+
tar xzf -
33+
34+
# Some versions of the EMSDK archive have their contents in .emsdk-portable
35+
# and others in emsdk_portable. Make sure the EMSDK ends up in a fixed path.
36+
if [ -d emsdk-portable ]; then
37+
mv emsdk-portable emsdk_portable
38+
fi
39+
40+
if [ ! -d emsdk_portable ]; then
41+
echo "ERROR: Invalid emsdk archive. Dumping working directory." >&2
42+
ls -l
43+
exit 1
44+
fi
45+
3346
source emsdk_portable/emsdk_env.sh
3447
hide_output emsdk update
3548
hide_output emsdk install --build=Release sdk-tag-1.37.1-32bit

0 commit comments

Comments
 (0)