mirror of
https://github.com/italicsjenga/winit-sonoma-fix.git
synced 2024-12-24 22:31:30 +11:00
a557b3cfb6
* Add web targets to travis * Fix some bash syntax * Avoid crash on providing no features * Fix syntax error * Syntax? * Fix pleas * Fix features check * Add a comment * Add nightly builds
103 lines
2.7 KiB
YAML
103 lines
2.7 KiB
YAML
language: rust
|
|
|
|
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
|
|
|
|
# Linux 64bit
|
|
- env: TARGET=x86_64-unknown-linux-gnu
|
|
os: linux
|
|
rust: nightly
|
|
- env: TARGET=x86_64-unknown-linux-gnu
|
|
os: linux
|
|
rust: stable
|
|
|
|
# macOS
|
|
- env: TARGET=x86_64-apple-darwin
|
|
os: osx
|
|
rust: nightly
|
|
- env: TARGET=x86_64-apple-darwin
|
|
os: osx
|
|
rust: stable
|
|
|
|
# iOS x86_64
|
|
- env: TARGET=x86_64-apple-ios
|
|
os: osx
|
|
rust: nightly
|
|
- env: TARGET=x86_64-apple-ios
|
|
os: osx
|
|
rust: stable
|
|
|
|
# iOS armv7
|
|
- env: TARGET=armv7-apple-ios
|
|
os: osx
|
|
rust: nightly
|
|
- env: TARGET=armv7-apple-ios
|
|
os: osx
|
|
rust: stable
|
|
|
|
# iOS arm64
|
|
- env: TARGET=aarch64-apple-ios
|
|
os: osx
|
|
rust: nightly
|
|
- env: TARGET=aarch64-apple-ios
|
|
os: osx
|
|
rust: stable
|
|
|
|
# wasm stdweb
|
|
- env: TARGET=wasm32-unknown-unknown WEB=web FEATURES=stdweb
|
|
os: linux
|
|
rust: stable
|
|
- env: TARGET=wasm32-unknown-unknown WEB=web FEATURES=stdweb
|
|
os: linux
|
|
rust: nightly
|
|
# wasm web-sys
|
|
- env: TARGET=wasm32-unknown-unknown FEATURES=web-sys
|
|
os: linux
|
|
rust: stable
|
|
- env: TARGET=wasm32-unknown-unknown FEATURES=web-sys
|
|
os: linux
|
|
rust: nightly
|
|
|
|
install:
|
|
- rustup self update
|
|
- rustup target add $TARGET; true
|
|
- rustup toolchain install stable
|
|
- rustup component add rustfmt --toolchain stable
|
|
|
|
script:
|
|
- cargo +stable fmt --all -- --check
|
|
# Install cargo-web to build stdweb
|
|
- if [[ $WEB = "web" ]]; then cargo install -f cargo-web; fi
|
|
# Build without serde then with serde
|
|
- if [[ -z "$FEATURES" ]]; then
|
|
cargo $WEB build --target $TARGET --verbose;
|
|
else
|
|
cargo $WEB build --target $TARGET --features $FEATURES --verbose;
|
|
fi
|
|
- cargo $WEB build --target $TARGET --features serde,$FEATURES --verbose
|
|
# Running iOS apps on macOS requires the Simulator so we skip that for now
|
|
# The web targets also don't support running tests
|
|
- if [[ $TARGET != *-apple-ios && $TARGET != wasm32-* ]]; then cargo test --target $TARGET --verbose; fi
|
|
- if [[ $TARGET != *-apple-ios && $TARGET != wasm32-* ]]; then cargo test --target $TARGET --features serde --verbose; fi
|
|
|
|
after_success:
|
|
- |
|
|
[ $TRAVIS_BRANCH = master ] &&
|
|
[ $TRAVIS_PULL_REQUEST = false ] &&
|
|
cargo publish --token ${CRATESIO_TOKEN}
|