2014-12-05 17:54:19 +03:00
|
|
|
#!/bin/bash -e
|
2017-05-26 18:03:46 +03:00
|
|
|
|
2016-10-15 18:59:23 +03:00
|
|
|
echo "Preparing for $TRAVIS_COMMIT_RANGE"
|
|
|
|
|
2017-05-26 18:03:46 +03:00
|
|
|
. util/travis/common.sh
|
|
|
|
|
2018-03-23 13:07:19 +03:00
|
|
|
if [[ ! -z "${CLANG_FORMAT}" ]]; then
|
2017-03-25 21:12:18 +03:00
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
2016-10-15 18:59:23 +03:00
|
|
|
needs_compile || exit 0
|
2014-12-05 17:54:19 +03:00
|
|
|
|
2018-03-23 13:07:19 +03:00
|
|
|
if [[ $PLATFORM == "Unix" ]] || [[ ! -z "${CLANG_TIDY}" ]]; then
|
|
|
|
if [[ $TRAVIS_OS_NAME == "linux" ]] || [[ ! -z "${CLANG_TIDY}" ]]; then
|
2017-05-26 18:03:46 +03:00
|
|
|
install_linux_deps
|
2016-01-29 17:15:58 +03:00
|
|
|
else
|
2017-05-26 18:03:46 +03:00
|
|
|
install_macosx_deps
|
2016-01-29 17:15:58 +03:00
|
|
|
fi
|
2015-02-28 02:05:29 +03:00
|
|
|
elif [[ $PLATFORM == "Win32" ]]; then
|
2020-03-08 23:05:12 +03:00
|
|
|
wget http://minetest.kitsunemimi.pw/mingw-w64-i686_9.2.0_ubuntu18.04.tar.xz -O mingw.tar.xz
|
2019-06-21 03:43:59 +03:00
|
|
|
# buildwin32.sh detects the installed toolchain automatically
|
2020-03-08 23:05:12 +03:00
|
|
|
sudo tar -xaf mingw.tar.xz -C /usr
|
2015-02-28 02:05:29 +03:00
|
|
|
elif [[ $PLATFORM == "Win64" ]]; then
|
2020-03-08 23:05:12 +03:00
|
|
|
wget http://minetest.kitsunemimi.pw/mingw-w64-x86_64_9.2.0_ubuntu18.04.tar.xz -O mingw.tar.xz
|
2015-02-28 02:05:29 +03:00
|
|
|
sed -e "s|%PREFIX%|x86_64-w64-mingw32|" \
|
|
|
|
-e "s|%ROOTPATH%|/usr/x86_64-w64-mingw32|" \
|
|
|
|
< util/travis/toolchain_mingw.cmake.in > util/buildbot/toolchain_mingw64.cmake
|
2020-03-08 23:05:12 +03:00
|
|
|
sudo tar -xaf mingw.tar.xz -C /usr
|
2014-12-05 17:54:19 +03:00
|
|
|
fi
|