Add support for OS X 10.10 in Travis CI builds

This downloads OS X 10.10 SDK, installs it and uses for compilation.

According to https://www.gosquared.com/global/mac/el-capitan/, current
market share among OS X versions is:
* 10.11 — 41.53%
* 10.10 — 38.65%
* 10.9  — 14.72%
* 10.8  — 5.60%
* 10.7  — 5.62%

I tried adding 10.9 SDK, but it fails to compile. With this change, we
should cover around 80% of OS X users.
This commit is contained in:
Michał Janiszewski 2016-01-08 12:22:57 +01:00
parent 683033d3f2
commit 7520bde6d3

View file

@ -3,6 +3,8 @@ language: c
before_install:
- if [[ $TRAVIS_OS_NAME == "linux" ]]; then bash scripts/linux/install.sh; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then gem install xcpretty-travis-formatter; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then curl -L https://openrct2.website/files/MacOSX10.10.sdk.tar.xz -o MacOSX10.10.sdk.tar.xz; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then sudo tar xf MacOSX10.10.sdk.tar.xz -C /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/; fi
sudo: required
dist: trusty
@ -24,7 +26,6 @@ matrix:
services:
- docker
- os: osx
sudo: false
osx_image: xcode7.2
after_success:
- cd build/Release
@ -56,7 +57,7 @@ matrix:
script:
- if [[ $TRAVIS_OS_NAME == "linux" ]]; then bash scripts/linux/build.sh ; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then set -o pipefail && xcodebuild | xcpretty -f `xcpretty-travis-formatter`; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then set -o pipefail && xcodebuild -sdk macosx10.10 | xcpretty -f `xcpretty-travis-formatter`; fi
notifications:
on_failure: change