Fix travis build with updated libinput
This commit is contained in:
parent
ed2174168d
commit
b0d4bdc36d
|
@ -2,3 +2,4 @@ target
|
||||||
Cargo.lock
|
Cargo.lock
|
||||||
*.bk
|
*.bk
|
||||||
.vscode
|
.vscode
|
||||||
|
.vagga
|
||||||
|
|
70
.travis.yml
70
.travis.yml
|
@ -1,40 +1,32 @@
|
||||||
language: rust
|
language: rust
|
||||||
|
|
||||||
cache: cargo
|
# We need this for the matrix, install is quick although unused
|
||||||
|
|
||||||
sudo: required
|
|
||||||
|
|
||||||
rust:
|
rust:
|
||||||
- stable
|
- stable
|
||||||
- beta
|
- beta
|
||||||
- nightly
|
- nightly
|
||||||
|
|
||||||
os:
|
sudo: required
|
||||||
- linux
|
|
||||||
|
|
||||||
dist: trusty
|
dist: trusty
|
||||||
|
|
||||||
|
# We cannot cache .vagga, because we actually do not have read permissions
|
||||||
|
# without sudo and travis cache script runs not as sudo...
|
||||||
|
cache:
|
||||||
|
directories:
|
||||||
|
- .vagga/stable-home
|
||||||
|
- .vagga/beta-home
|
||||||
|
- .vagga/nightly-home
|
||||||
|
- .vagga/.cache
|
||||||
|
|
||||||
addons:
|
addons:
|
||||||
apt:
|
apt:
|
||||||
packages:
|
packages:
|
||||||
- libssl-dev
|
- libcurl4-openssl-dev
|
||||||
- libudev-dev
|
- libelf-dev
|
||||||
- libgbm-dev
|
- libdw-dev
|
||||||
- libxkbcommon-dev
|
|
||||||
- libegl1-mesa-dev
|
|
||||||
|
|
||||||
before_install:
|
|
||||||
- sudo add-apt-repository -y ppa:wayland.admin/daily-builds
|
|
||||||
- sudo apt-get update -qq || echo "Ignoring failed apt-get update..."
|
|
||||||
- sudo apt-get install -y libwayland-dev libinput-dev
|
|
||||||
|
|
||||||
branches:
|
|
||||||
only:
|
|
||||||
- master
|
|
||||||
|
|
||||||
env:
|
env:
|
||||||
global:
|
|
||||||
- RUST_BACKTRACE=1
|
|
||||||
matrix:
|
matrix:
|
||||||
- FEATURES=""
|
- FEATURES=""
|
||||||
# test individual features
|
# test individual features
|
||||||
|
@ -58,38 +50,36 @@ matrix:
|
||||||
- rust: nightly
|
- rust: nightly
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- export PATH=$HOME/.local/bin:$HOME/.cargo/bin:$PATH
|
- 'echo ubuntu-mirror: http://mirrors.us.kernel.org/ubuntu/ > ~/.vagga.yaml'
|
||||||
|
- 'echo alpine-mirror: http://mirrors.gigenet.com/alpinelinux/ >> ~/.vagga.yaml'
|
||||||
- |
|
- |
|
||||||
if [ "$FEATURES" = "cargo-fmt" ]; then
|
echo "$(id -un):100000:65536" | sudo tee /etc/subuid | sudo tee /etc/subgid
|
||||||
cargo install rustfmt-nightly --force;
|
sudo apt-get install uidmap -y
|
||||||
fi
|
curl http://files.zerogw.com/vagga/vagga-install.sh | sh
|
||||||
- |
|
- vagga update-$TRAVIS_RUST_VERSION
|
||||||
if [ "$FEATURES" = "cargo-clippy" ]; then
|
|
||||||
cargo install clippy --force;
|
|
||||||
fi
|
|
||||||
- mkdir $(pwd)/socket
|
|
||||||
- export XDG_RUNTIME_DIR="$(pwd)/socket"
|
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- |
|
- |
|
||||||
case $FEATURES in
|
case $FEATURES in
|
||||||
"all")
|
"all")
|
||||||
cargo test --all-features &&
|
vagga cargo-$TRAVIS_RUST_VERSION test --all-features &&
|
||||||
cargo doc --no-deps --all-features
|
vagga cargo-$TRAVIS_RUST_VERSION doc --no-deps --all-features
|
||||||
;;
|
;;
|
||||||
"default")
|
"default")
|
||||||
cargo test &&
|
vagga cargo-$TRAVIS_RUST_VERSION test &&
|
||||||
cargo doc --no-deps
|
vagga cargo-$TRAVIS_RUST_VERSION doc --no-deps
|
||||||
;;
|
;;
|
||||||
"cargo-fmt")
|
"cargo-fmt")
|
||||||
cargo fmt -- --write-mode=diff
|
vagga cargo-$TRAVIS_RUST_VERSION install -f rustfmt-nightly &&
|
||||||
|
vagga cargo-$TRAVIS_RUST_VERSION fmt -- --write-mode=diff
|
||||||
;;
|
;;
|
||||||
"cargo-clippy")
|
"cargo-clippy")
|
||||||
cargo clippy --all-features -- -D warnings
|
vagga cargo-$TRAVIS_RUST_VERSION install -f clippy &&
|
||||||
|
vagga cargo-$TRAVIS_RUST_VERSION clippy --all-features -- -D warnings
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
cargo test --lib --doc --tests --no-default-features --features "$FEATURES" &&
|
vagga cargo-$TRAVIS_RUST_VERSION test --lib --doc --tests --no-default-features --features "$FEATURES" &&
|
||||||
cargo doc --no-deps --no-default-features --features "$FEATURES"
|
vagga cargo-$TRAVIS_RUST_VERSION doc --no-deps --no-default-features --features "$FEATURES"
|
||||||
esac
|
esac
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
|
|
|
@ -0,0 +1,77 @@
|
||||||
|
minimum-vagga: v0.5.0
|
||||||
|
|
||||||
|
containers:
|
||||||
|
base:
|
||||||
|
auto-clean: true
|
||||||
|
setup:
|
||||||
|
- !UbuntuRelease { codename: artful }
|
||||||
|
- !UbuntuUniverse
|
||||||
|
- !Install [build-essential, wget, curl, pkg-config, file, openssl, sudo, ca-certificates, libssl-dev, cmake, libudev-dev, libgbm-dev, libxkbcommon-dev, libegl1-mesa-dev, libwayland-dev, libinput-dev]
|
||||||
|
|
||||||
|
stable:
|
||||||
|
auto-clean: true
|
||||||
|
environ:
|
||||||
|
HOME: /work/.vagga/stable-home
|
||||||
|
PATH: /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/work/.vagga/stable-home/.cargo/bin:/work/.vagga/stable-home/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/
|
||||||
|
RUST_BACKTRACE: 1
|
||||||
|
XDG_RUNTIME_DIR: /work/.vagga/stable-home
|
||||||
|
setup:
|
||||||
|
- !Container base
|
||||||
|
- !Env HOME: /work/.vagga/stable-home
|
||||||
|
- !Sh curl https://sh.rustup.rs -sSf | sh -s -- -y --default-host x86_64-unknown-linux-gnu --default-toolchain stable --no-modify-path
|
||||||
|
|
||||||
|
beta:
|
||||||
|
auto-clean: true
|
||||||
|
environ:
|
||||||
|
HOME: /work/.vagga/beta-home
|
||||||
|
PATH: /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/work/.vagga/beta-home/.cargo/bin:/work/.vagga/beta-home/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/
|
||||||
|
RUST_BACKTRACE: 1
|
||||||
|
XDG_RUNTIME_DIR: /work/.vagga/beta-home
|
||||||
|
setup:
|
||||||
|
- !Container base
|
||||||
|
- !Env HOME: /work/.vagga/beta-home
|
||||||
|
- !Sh curl https://sh.rustup.rs -sSf | sh -s -- -y --default-host x86_64-unknown-linux-gnu --default-toolchain beta --no-modify-path
|
||||||
|
|
||||||
|
nightly:
|
||||||
|
auto-clean: true
|
||||||
|
environ:
|
||||||
|
HOME: /work/.vagga/nightly-home
|
||||||
|
PATH: /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/work/.vagga/nightly-home/.cargo/bin:/work/.vagga/nightly-home/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/
|
||||||
|
RUST_BACKTRACE: 1
|
||||||
|
XDG_RUNTIME_DIR: /work/.vagga/nightly-home
|
||||||
|
setup:
|
||||||
|
- !Container base
|
||||||
|
- !Env HOME: /work/.vagga/nightly-home
|
||||||
|
- !Sh curl https://sh.rustup.rs -sSf | sh -s -- -y --default-host x86_64-unknown-linux-gnu --default-toolchain nightly --no-modify-path
|
||||||
|
|
||||||
|
commands:
|
||||||
|
update-stable: !Command
|
||||||
|
description: Update container
|
||||||
|
container: stable
|
||||||
|
run: rustup update
|
||||||
|
|
||||||
|
update-beta: !Command
|
||||||
|
description: Update container
|
||||||
|
container: beta
|
||||||
|
run: rustup update
|
||||||
|
|
||||||
|
update-nightly: !Command
|
||||||
|
description: Update container
|
||||||
|
container: nightly
|
||||||
|
run: |
|
||||||
|
rustup update
|
||||||
|
|
||||||
|
cargo-stable: !Command
|
||||||
|
description: Run cargo
|
||||||
|
container: stable
|
||||||
|
run: ["/work/.vagga/stable-home/.cargo/bin/cargo"]
|
||||||
|
|
||||||
|
cargo-beta: !Command
|
||||||
|
description: Run cargo
|
||||||
|
container: beta
|
||||||
|
run: ["/work/.vagga/beta-home/.cargo/bin/cargo"]
|
||||||
|
|
||||||
|
cargo-nightly: !Command
|
||||||
|
description: Run cargo
|
||||||
|
container: nightly
|
||||||
|
run: ["/work/.vagga/nightly-home/.cargo/bin/cargo"]
|
Loading…
Reference in New Issue