Skip to content

Commit

Permalink
Switch Windows CI builds from windows-gnu to windows-msvc.
Browse files Browse the repository at this point in the history
The Travis default of windows-gnu suffers from rust-lang/rust#47048, I
think. I don't see an easy way to address this right now, but switching
our Windows builds to windows-msvc will avoid this and is more realistic
target anyway.
  • Loading branch information
kinetiknz committed Mar 11, 2020
1 parent aeef39b commit b88ed9d
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,24 @@ os:
- linux
- osx
- windows

env:
matrix:
- RELEASE=
- RELEASE=--release

before_script:
# rustfmt may not always be available in nightly
- if [[ "$TRAVIS_RUST_VERSION" != *nightly* ]]; then rustup component add rustfmt; fi
install:
# rustfmt may not always be available in nightly
- if [[ "$TRAVIS_RUST_VERSION" != *nightly* ]]; then rustup component add rustfmt; fi
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then T=x86_64-pc-windows-msvc; rustup target add $T; TARGET=--target=$T; fi

script:
# We cannot run `cargo test` with the mp4parse_fallible feature enabled
# (see comment where the feature is defined in mp4parse_capi/Cargo.toml),
# but we can at least check for changes behind features that would break the
# build.
- cargo check --all --verbose $RELEASE --tests --all-features
- cargo test --all --verbose $RELEASE
- cargo test --all --verbose $RELEASE $TARGET
- cargo doc --package mp4parse_capi
# The `false` after `echo` is necessary to avoid false negatives due to `echo` returning success
- if [[ "$TRAVIS_RUST_VERSION" != *nightly* ]]; then cargo fmt -- --check || (echo "Please reformat your code with 'cargo fmt' (version $(cargo fmt -- --version))"; false); fi

0 comments on commit b88ed9d

Please sign in to comment.