2014-07-31 02:04:48 +10:00
|
|
|
language: rust
|
2014-08-03 17:25:30 +10:00
|
|
|
|
2016-09-06 16:46:31 +10:00
|
|
|
cache: cargo
|
|
|
|
|
2017-10-09 00:51:55 +11:00
|
|
|
matrix:
|
|
|
|
include:
|
|
|
|
# Linux 32bit
|
|
|
|
- env: TARGET=i686-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: nightly
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
# Cross compiler and cross compiled C libraries
|
|
|
|
packages: &i686_packages
|
|
|
|
- gcc-multilib
|
|
|
|
- env: TARGET=i686-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: stable
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages: *i686_packages
|
2018-06-03 12:59:59 +10:00
|
|
|
- env: TARGET=i686-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: 1.24.1
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages: *i686_packages
|
2017-10-09 00:51:55 +11:00
|
|
|
|
|
|
|
# Linux 64bit
|
|
|
|
- env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: nightly
|
|
|
|
- env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: stable
|
2018-06-03 12:59:59 +10:00
|
|
|
- env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
os: linux
|
|
|
|
rust: 1.24.1
|
2017-10-09 00:51:55 +11:00
|
|
|
|
|
|
|
# macOS
|
|
|
|
- env: TARGET=x86_64-apple-darwin
|
|
|
|
os: osx
|
|
|
|
rust: nightly
|
|
|
|
- env: TARGET=x86_64-apple-darwin
|
|
|
|
os: osx
|
|
|
|
rust: stable
|
2018-06-03 12:59:59 +10:00
|
|
|
- env: TARGET=x86_64-apple-darwin
|
|
|
|
os: osx
|
|
|
|
rust: 1.24.1
|
2017-10-09 00:51:55 +11:00
|
|
|
|
|
|
|
# iOS
|
|
|
|
- env: TARGET=x86_64-apple-ios
|
|
|
|
os: osx
|
|
|
|
rust: nightly
|
|
|
|
- env: TARGET=x86_64-apple-ios
|
|
|
|
os: osx
|
|
|
|
rust: stable
|
2018-06-03 12:59:59 +10:00
|
|
|
- env: TARGET=x86_64-apple-ios
|
|
|
|
os: osx
|
|
|
|
rust: 1.24.1
|
2017-10-09 00:51:55 +11:00
|
|
|
|
2016-12-14 00:37:13 +11:00
|
|
|
install:
|
2017-09-05 16:26:05 +10:00
|
|
|
- rustup self update
|
2017-10-09 00:51:55 +11:00
|
|
|
- rustup target add $TARGET; true
|
2016-12-14 00:37:13 +11:00
|
|
|
|
2018-11-13 12:37:51 +11:00
|
|
|
before_script:
|
|
|
|
- |
|
|
|
|
if [ "$TRAVIS_RUST_VERSION" == "1.24.1" ]; then
|
|
|
|
# Some of winit's transitive dependencies have made semver-compatible releases that actually
|
|
|
|
# break their compatibility with rust 1.24.1. We freeze them to their last compatible version to
|
|
|
|
# ensure that winit still compiles fine on this rust version.
|
|
|
|
cargo update
|
|
|
|
cargo update -p stb_truetype --precise 0.2.2
|
|
|
|
cargo update -p rusttype --precise 0.7.1
|
|
|
|
fi
|
|
|
|
|
2014-10-05 04:17:02 +11:00
|
|
|
script:
|
2017-10-09 00:51:55 +11:00
|
|
|
- cargo build --target $TARGET --verbose
|
2018-11-01 19:24:56 +11:00
|
|
|
- cargo build --target $TARGET --features serde --verbose
|
|
|
|
- cargo build --target $TARGET --features icon_loading --verbose
|
2017-10-09 00:51:55 +11:00
|
|
|
# Running iOS apps on OSX requires the simulator so we skip that for now
|
|
|
|
- if [ "$TARGET" != "x86_64-apple-ios" ]; then cargo test --target $TARGET --verbose; fi
|
2018-11-01 19:24:56 +11:00
|
|
|
- if [ "$TARGET" != "x86_64-apple-ios" ]; then cargo test --target $TARGET --features serde --verbose; fi
|
|
|
|
- if [ "$TARGET" != "x86_64-apple-ios" ]; then cargo test --target $TARGET --features icon_loading --verbose; fi
|
2014-12-17 20:33:49 +11:00
|
|
|
|
2016-12-14 00:28:30 +11:00
|
|
|
after_success:
|
2015-02-16 00:05:08 +11:00
|
|
|
- |
|
2015-02-16 00:58:47 +11:00
|
|
|
[ $TRAVIS_BRANCH = master ] &&
|
|
|
|
[ $TRAVIS_PULL_REQUEST = false ] &&
|
|
|
|
cargo publish --token ${CRATESIO_TOKEN}
|