Browse Source

Check blobs in separate target

Vadim Kaushan 6 years ago
parent
commit
a8040bd24b
3 changed files with 17 additions and 7 deletions
  1. 4 0
      .travis.yml
  2. 7 3
      ci/install.sh
  3. 6 4
      ci/script.sh

+ 4 - 0
.travis.yml

@@ -20,6 +20,10 @@ matrix:
       rust: nightly
       if: (branch = staging OR branch = trying OR branch = master) OR (type = pull_request AND branch = master)
 
+    - env: CHECK_BLOBS=1
+      rust: stable
+      if: (branch = staging OR branch = trying OR branch = master) OR (type = pull_request AND branch = master)
+
 
 install:
   - ci/install.sh

+ 7 - 3
ci/install.sh

@@ -2,7 +2,11 @@
 
 set -euxo pipefail
 
-rustup target add $TARGET
+if [ -n "${TARGET:-}" ]; then
+    rustup target add $TARGET
+fi
 
-mkdir gcc
-curl -L https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-linux-ubuntu14.tar.gz | tar --strip-components=1 -C gcc -xz
+if [ -n "${CHECK_BLOBS:-}" ]; then
+    mkdir gcc
+    curl -L https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-linux-ubuntu14.tar.gz | tar --strip-components=1 -C gcc -xz
+fi

+ 6 - 4
ci/script.sh

@@ -2,12 +2,14 @@
 
 set -euxo pipefail
 
-cargo check --target $TARGET
+if [ -n "${TARGET:-}" ]; then
+    cargo check --target $TARGET
 
-if [ $TRAVIS_RUST_VERSION = nightly ]; then
-    cargo check --target $TARGET --features inline-asm
+    if [ $TRAVIS_RUST_VERSION = nightly ]; then
+        cargo check --target $TARGET --features inline-asm
+    fi
 fi
 
-if [ $TARGET = x86_64-unknown-linux-gnu ]; then
+if [ -n "${CHECK_BLOBS:-}" ]; then
     ./check-blobs.sh
 fi