Skip to content
Permalink
Browse files

Deny warnings in rust code globally in CI

Use the new environment variable support for `buildbot_steps.yml`
to do this globally instead of having to patch every call,
which is error prone.

Set this variable globally in .travis.yml and appveyor.yml as well.
  • Loading branch information
aneeshusa authored and SimonSapin committed Jan 9, 2018
1 parent d0abd1c commit e9eaadc913c62ee62d90bcacdf61436034543a54
Showing with 26 additions and 22 deletions.
  1. +7 −5 .travis.yml
  2. +1 −1 appveyor.yml
  3. +18 −16 etc/ci/buildbot_steps.yml
@@ -20,11 +20,11 @@ matrix:
- export LLVM_CONFIG=/usr/lib/llvm-3.9/bin/llvm-config
- export CC=gcc-5 CXX=g++-5
script:
- RUSTFLAGS='-D warnings' ./mach build -d --verbose
- RUSTFLAGS='-D warnings' ./mach test-unit
- ./mach build -d --verbose
- ./mach test-unit
- ./mach clean
- RUSTFLAGS='-D warnings' ./mach build-geckolib
- RUSTFLAGS='-D warnings' ./mach test-stylo
- ./mach build-geckolib
- ./mach test-stylo
- bash etc/ci/lockfile_changed.sh
cache:
directories:
@@ -34,7 +34,9 @@ matrix:
before_cache:
- ./mach clean-nightlies --keep 2 --force
- ./mach clean-cargo-cache --keep 2 --force
env: CCACHE=/usr/bin/ccache
env:
CCACHE=/usr/bin/ccache
RUSTFLAGS=-Dwarnings
addons:
apt:
sources:
@@ -3,6 +3,7 @@ version: 1.0.{build}
environment:
CCACHE_DIR: "%APPVEYOR_BUILD_FOLDER%\\.ccache"
RUST_BACKTRACE: 1
RUSTFLAGS: -Dwarnings
# The appveyor image we use has a pretty huge set of things installed... we make the
# initial PATH something sane so we know what to expect
PATH: "C:\\windows\\system32;\
@@ -48,7 +49,6 @@ cache:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))

build_script:
- set RUSTFLAGS=-D warnings
- mach build -d -v
- mach test-unit

@@ -1,3 +1,6 @@
env:
RUSTFLAGS: -Dwarnings

mac-rel-wpt1:
- ./mach clean-nightlies --keep 3 --force
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig ./mach build --release
@@ -32,11 +35,11 @@ mac-rel-wpt4:

mac-dev-unit:
- ./mach clean-nightlies --keep 3 --force
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig RUSTFLAGS=-Dwarnings ./mach build --dev
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig RUSTFLAGS=-Dwarnings ./mach test-unit
- env ./mach package --dev
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig RUSTFLAGS=-Dwarnings ./mach build-cef
- env RUSTFLAGS=-Dwarnings ./mach build-geckolib
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig ./mach build --dev
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig ./mach test-unit
- ./mach package --dev
- env PKG_CONFIG_PATH=/usr/local/opt/zlib/lib/pkgconfig ./mach build-cef
- ./mach build-geckolib
- bash ./etc/ci/lockfile_changed.sh
- bash ./etc/ci/manifest_changed.sh

@@ -80,13 +83,13 @@ linux-dev:
- ./mach clean-nightlies --keep 3 --force
- ./mach test-tidy --no-progress --all
- ./mach test-tidy --no-progress --self-test
- env CC=gcc-5 CXX=g++-5 RUSTFLAGS=-Dwarnings ./mach build --dev
- env CC=gcc-5 CXX=g++-5 RUSTFLAGS=-Dwarnings ./mach test-unit
- env ./mach package --dev
- env CC=gcc-5 CXX=g++-5 RUSTFLAGS=-Dwarnings ./mach build-cef
- env CC=gcc-5 CXX=g++-5 RUSTFLAGS=-Dwarnings ./mach build --dev --no-default-features --features default-except-unstable
- env RUSTFLAGS=-Dwarnings ./mach build-geckolib
- env RUSTFLAGS=-Dwarnings ./mach test-stylo
- env CC=gcc-5 CXX=g++-5 ./mach build --dev
- env CC=gcc-5 CXX=g++-5 ./mach test-unit
- ./mach package --dev
- env CC=gcc-5 CXX=g++-5 ./mach build-cef
- env CC=gcc-5 CXX=g++-5 ./mach build --dev --no-default-features --features default-except-unstable
- ./mach build-geckolib
- ./mach test-stylo
- bash ./etc/ci/lockfile_changed.sh
- bash ./etc/ci/manifest_changed.sh
- bash ./etc/ci/check_no_panic.sh
@@ -120,7 +123,7 @@ linux-nightly:

android:
- ./mach clean-nightlies --keep 3 --force
- env ANDROID_SDK=/home/servo/android/sdk/r25.2.3 RUSTFLAGS=-Dwarnings ./mach build --android --dev
- env ANDROID_SDK=/home/servo/android/sdk/r25.2.3 ./mach build --android --dev
- env ANDROID_SDK=/home/servo/android/sdk/r25.2.3 ./mach package --android --dev
- bash ./etc/ci/lockfile_changed.sh
- bash ./etc/ci/manifest_changed.sh
@@ -134,19 +137,18 @@ android-nightly:

arm32:
- ./mach clean-nightlies --keep 3 --force
- env RUSTFLAGS=-Dwarnings ./mach build --rel --target=arm-unknown-linux-gnueabihf
- ./mach build --rel --target=arm-unknown-linux-gnueabihf
- bash ./etc/ci/lockfile_changed.sh
- bash ./etc/ci/manifest_changed.sh

arm64:
- ./mach clean-nightlies --keep 3 --force
- env RUSTFLAGS=-Dwarnings ./mach build --rel --target=aarch64-unknown-linux-gnu
- ./mach build --rel --target=aarch64-unknown-linux-gnu
- bash ./etc/ci/lockfile_changed.sh
- bash ./etc/ci/manifest_changed.sh

windows-msvc-dev:
- mach.bat clean-nightlies --keep 3 --force
- set RUSTFLAGS=-D warnings
- mach.bat build --dev
- mach.bat test-unit
- mach.bat package --dev

0 comments on commit e9eaadc

Please sign in to comment.
You can’t perform that action at this time.