diff --git a/build.sh b/build.sh index 1f2bbd265486f15af5c84bdcc4cd4bcb3afc91dd..61d4faee47e39799f66bc0a8421c381860c6bdae 100755 --- a/build.sh +++ b/build.sh @@ -150,7 +150,7 @@ check_prerequisites() echo "Checking prerequisites..." | tee -a $LOGFILE # required toolchain - TOOLS="automake autoconf m4 cmake wget svn tar patch gcc g++ ld libtool libtoolize ar lex yacc pkg-config hg" + TOOLS="automake autoconf m4 cmake wget svn tar patch gcc g++ ld libtool libtoolize ar lex yacc pkg-config" MISSING="" for tool in $TOOLS; do @@ -219,15 +219,14 @@ prepare_sdl() mkdir -p $ROOT/3rdparty/sdl >> $LOGFILE || failure mkdir -p $ROOT/build/sdl >> $LOGFILE || failure - cd $ROOT/3rdparty/sdl || failure - if [ -d .hg ]; then - echo "Updating SDL..." | tee -a $LOGFIL - # local changes (patches) are reverted, hence also updated - hg update --clean >> $LOGFILE 2>&1 || failure - else - echo "Retrieving SDL $SDL_VERSION (this may take a while)..." | tee -a $LOGFILE - hg clone -r release-$SDL_VERSION http://hg.libsdl.org/SDL . >> $LOGFILE 2>&1 || failure - fi + echo "Retrieving SDL $SDL_VERSION (this may take a while)..." | tee -a $LOGFILE + cd $ROOT/3rdparty || failure + wget https://www.libsdl.org/release/SDL2-$SDL_VERSION.tar.gz >> $LOGFILE 2>&1 || failure + tar -xzf SDL2-$SDL_VERSION.tar.gz >> $LOGFILE 2>&1 || failure + rm SDL2-$SDL_VERSION.tar.gz >> $LOGFILE 2>&1 || failure + # substitute old source tree + rm -rf sdl >> $LOGFILE 2>&1 || failure + mv SDL2-$SDL_VERSION sdl >> $LOGFILE 2>&1 || failure return 0 }