mirror of
https://github.com/OpenRCT2/OpenRCT2.git
synced 2025-01-23 10:51:58 -05:00
37434bd6c2
reduce verbosity try using .cache folder valid travis file name file push travis notifications to openrct2-dev list directory contents untar in the subfolder see whats in that directory ls more dirs .patch is in subdir too dont be a dummy only download if files arent present syntax check correct files check if anything is in cache try filename with no period
39 lines
1.8 KiB
YAML
39 lines
1.8 KiB
YAML
language: c
|
|
|
|
before_install:
|
|
- sudo apt-get install -y --force-yes binutils-mingw-w64-i686 gcc-mingw-w64-i686 g++-mingw-w64-i686
|
|
|
|
# fetch precompiled SDL2 + headers for MinGW and push it into the expected directory
|
|
- mkdir -p cache
|
|
- export SDL2_PV=2.0.3
|
|
- if [[ ! -f cache/SDL2-devel-${SDL2_PV}-mingw.tar.gz ]]; then wget http://libsdl.org/release/SDL2-devel-${SDL2_PV}-mingw.tar.gz --output-document cache/SDL2-devel-${SDL2_PV}-mingw.tar.gz; fi
|
|
- pushd cache && tar -xzf SDL2-devel-${SDL2_PV}-mingw.tar.gz && popd
|
|
|
|
# but first fix SDL2 bug
|
|
- if [[ ! -f cache/libsdl2-mingw-2.0.3-fix-platform-detection-for-mingw.patch ]]; then wget "https://github.com/anyc/anyc-overlay/raw/master/media-libs/libsdl2-mingw/files/libsdl2-mingw-2.0.3-fix-platform-detection-for-mingw.patch" --output-document cache/libsdl2-mingw-2.0.3-fix-platform-detection-for-mingw.patch; fi
|
|
- pushd cache/SDL2-${SDL2_PV}/i686-w64-mingw32/include/SDL2/ && patch -p2 < ../../../../libsdl2-mingw-2.0.3-fix-platform-detection-for-mingw.patch && popd
|
|
|
|
- sudo mkdir -p /usr/local/cross-tools/
|
|
- sudo cp -r cache/SDL2-${SDL2_PV}/i686-w64-mingw32 /usr/local/cross-tools/
|
|
|
|
# build a wrapper that looks for the sdl2.pc file in the new directory
|
|
- echo -e "#! /bin/sh\\nexport PKG_CONFIG_LIBDIR=/usr/local/cross-tools/i686-w64-mingw32/lib/pkgconfig\\npkg-config \$@" > i686-w64-mingw32-pkg-config
|
|
- chmod +x i686-w64-mingw32-pkg-config
|
|
- sudo mv i686-w64-mingw32-pkg-config /usr/local/bin/
|
|
|
|
script:
|
|
- mkdir build
|
|
- pushd build
|
|
- cmake -DCMAKE_TOOLCHAIN_FILE=../CMakeLists_mingw.txt -DCMAKE_BUILD_TYPE=Debug ..
|
|
- make
|
|
- popd
|
|
|
|
notifications:
|
|
irc: "irc.freenode.net#openrct2-dev"
|
|
on_failure: always
|
|
on_success: change
|
|
|
|
cache:
|
|
directories:
|
|
- cache
|
|
apt: true
|