File tree 7 files changed +73
-11
lines changed
7 files changed +73
-11
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,15 @@ sudo: false
3
3
4
4
matrix :
5
5
include :
6
+ - env : TARGET=thumbv6m-none-eabi
7
+ os : linux
8
+ sudo : required
9
+ - env : TARGET=thumbv7m-none-eabi
10
+ os : linux
11
+ sudo : required
12
+ - env : TARGET=thumbv7em-none-eabi
13
+ os : linux
14
+ sudo : required
6
15
- env : TARGET=i586-unknown-linux-gnu
7
16
os : linux
8
17
services : docker
@@ -84,6 +93,16 @@ matrix:
84
93
os : osx
85
94
- env : TARGET=x86_64-unknown-linux-gnu
86
95
os : linux
96
+ allow_failures :
97
+ # Issue #2. Flaky test
98
+ - env : TARGET=arm-unknown-linux-gnueabi
99
+ os : linux
100
+ # Issue #2. Flaky test
101
+ - env : TARGET=arm-unknown-linux-gnueabihf
102
+ os : linux
103
+ # Issue #2. Flaky test
104
+ - env : TARGET=armv7-unknown-linux-gnueabihf
105
+ os : linux
87
106
88
107
before_install :
89
108
- export PATH="$PATH:$HOME/.cargo/bin"
Original file line number Diff line number Diff line change @@ -25,8 +25,6 @@ case $TARGET in
25
25
export QEMU_LD_PREFIX=/usr/arm-linux-gnueabihf
26
26
;;
27
27
armv7-unknown-linux-gnueabihf)
28
- # See #2
29
- export DONT_RUN_TESTS=y
30
28
export PREFIX=arm-linux-gnueabihf-
31
29
export QEMU_LD_PREFIX=/usr/arm-linux-gnueabihf
32
30
;;
@@ -65,13 +63,19 @@ case $TARGET in
65
63
export QEMU_LD_PREFIX=/usr/powerpc64-linux-gnu
66
64
;;
67
65
powerpc64le-unknown-linux-gnu)
68
- # See #2
69
- export DONT_RUN_TESTS=y
70
66
if [[ -z $DOCKER ]]; then
71
67
export DOCKER=y
72
68
fi
73
69
export PREFIX=powerpc64le-linux-gnu-
74
70
export QEMU=qemu-ppc64le
75
71
export QEMU_LD_PREFIX=/usr/powerpc64le-linux-gnu
72
+ # Issue #2. QEMU doesn't work
73
+ export RUN_TESTS=n
74
+ ;;
75
+ thumbv* -none-eabi)
76
+ export CARGO=xargo
77
+ export PREFIX=arm-none-eabi-
78
+ # Bare metal targets. No `std` or `test` crates for these targets.
79
+ export RUN_TESTS=n
76
80
;;
77
81
esac
Original file line number Diff line number Diff line change @@ -32,7 +32,13 @@ install_binutils() {
32
32
osx)
33
33
brew install binutils
34
34
;;
35
- * )
35
+ linux)
36
+ case $TARGET in
37
+ thumbv* -none-eabi)
38
+ sudo apt-get install -y --no-install-recommends \
39
+ binutils-arm-none-eabi
40
+ ;;
41
+ esac
36
42
;;
37
43
esac
38
44
}
@@ -79,6 +85,12 @@ add_rustup_target() {
79
85
fi
80
86
}
81
87
88
+ install_xargo () {
89
+ if [[ $CARGO == " xargo" ]]; then
90
+ curl -sf " https://raw.githubusercontent.com/japaric/rust-everywhere/master/install.sh" | bash -s -- --from japaric/xargo
91
+ fi
92
+ }
93
+
82
94
configure_cargo () {
83
95
if [[ $PREFIX ]]; then
84
96
${PREFIX} gcc -v
@@ -99,6 +111,7 @@ main() {
99
111
install_c_toolchain
100
112
install_rust
101
113
add_rustup_target
114
+ install_xargo
102
115
configure_cargo
103
116
fi
104
117
}
Original file line number Diff line number Diff line change 3
3
. $( dirname $0 ) /env.sh
4
4
5
5
build () {
6
- cargo build --target $TARGET
7
- cargo build --target $TARGET --release
6
+ ${CARGO :- cargo} build --target $TARGET
7
+ ${CARGO :- cargo} build --target $TARGET --release
8
8
}
9
9
10
10
run_tests () {
@@ -14,14 +14,14 @@ run_tests() {
14
14
15
15
if [[ $QEMU ]]; then
16
16
cargo test --target $TARGET --no-run
17
- if [[ -z $DONT_RUN_TESTS ]]; then
17
+ if [[ ${RUN_TESTS :- y} == " y " ]]; then
18
18
$QEMU target/** /debug/rustc_builtins-*
19
19
fi
20
20
cargo test --target $TARGET --release --no-run
21
- if [[ -z $DONT_RUN_TESTS ]]; then
21
+ if [[ ${RUN_TESTS :- y} == " y " ]]; then
22
22
$QEMU target/** /release/rustc_builtins-*
23
23
fi
24
- elif [[ -z $DONT_RUN_TESTS ]]; then
24
+ elif [[ ${RUN_TESTS :- y} == " y " ]]; then
25
25
cargo test --target $TARGET
26
26
cargo test --target $TARGET --release
27
27
fi
@@ -50,8 +50,8 @@ main() {
50
50
bash ci/script.sh'
51
51
else
52
52
build
53
- run_tests
54
53
inspect
54
+ run_tests
55
55
fi
56
56
}
57
57
Original file line number Diff line number Diff line change
1
+ {
2
+ "arch" : " arm" ,
3
+ "data-layout" : " e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" ,
4
+ "features" : " +strict-align" ,
5
+ "llvm-target" : " thumbv6m-none-eabi" ,
6
+ "max-atomic-width" : 0 ,
7
+ "os" : " none" ,
8
+ "target-endian" : " little" ,
9
+ "target-pointer-width" : " 32"
10
+ }
Original file line number Diff line number Diff line change
1
+ {
2
+ "arch" : " arm" ,
3
+ "data-layout" : " e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" ,
4
+ "llvm-target" : " thumbv7em-none-eabi" ,
5
+ "os" : " none" ,
6
+ "target-endian" : " little" ,
7
+ "target-pointer-width" : " 32"
8
+ }
Original file line number Diff line number Diff line change
1
+ {
2
+ "arch" : " arm" ,
3
+ "data-layout" : " e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" ,
4
+ "llvm-target" : " thumbv7m-none-eabi" ,
5
+ "os" : " none" ,
6
+ "target-endian" : " little" ,
7
+ "target-pointer-width" : " 32"
8
+ }
You can’t perform that action at this time.
0 commit comments