Skip to content

Commit 0f7f1ba

Browse files
committed
Add armv7-unknown-linux-musleabihf host tools to CI
1 parent 75e7cf5 commit 0f7f1ba

File tree

3 files changed

+56
-0
lines changed

3 files changed

+56
-0
lines changed
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
FROM ubuntu:22.04
2+
3+
COPY scripts/cross-apt-packages.sh /scripts/
4+
RUN sh /scripts/cross-apt-packages.sh
5+
6+
COPY scripts/crosstool-ng.sh /scripts/
7+
RUN sh /scripts/crosstool-ng.sh
8+
9+
COPY scripts/rustbuild-setup.sh /scripts/
10+
RUN sh /scripts/rustbuild-setup.sh
11+
WORKDIR /tmp
12+
13+
COPY scripts/crosstool-ng-build.sh /scripts/
14+
COPY host-x86_64/dist-armv7-linux-musl/armv7-unknown-linux-musleabihf.defconfig /tmp/crosstool.defconfig
15+
RUN /scripts/crosstool-ng-build.sh
16+
17+
COPY scripts/sccache.sh /scripts/
18+
RUN sh /scripts/sccache.sh
19+
20+
ENV PATH=$PATH:/x-tools/armv7-unknown-linux-musleabihf/bin
21+
22+
ENV CC_armv7_unknown_linux_musleabihf=armv7-unknown-linux-musleabihf-gcc \
23+
AR_armv7_unknown_linux_musleabihf=armv7-unknown-linux-musleabihf-ar \
24+
CXX_armv7_unknown_linux_musleabihf=armv7-unknown-linux-musleabihf-g++
25+
26+
ENV HOSTS=armv7-unknown-linux-musleabihf
27+
28+
ENV RUST_CONFIGURE_ARGS \
29+
--enable-extended \
30+
--enable-full-tools \
31+
--enable-profiler \
32+
--enable-sanitizers \
33+
--disable-docs \
34+
--set target.armv7-unknown-linux-musleabihf.crt-static=false \
35+
--musl-root-armv7hf=/x-tools/armv7-unknown-linux-musleabihf/armv7-unknown-linux-musleabihf/sysroot/usr
36+
37+
ENV SCRIPT python3 ../x.py dist --host $HOSTS --target $HOSTS
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
CT_CONFIG_VERSION="4"
2+
CT_PREFIX_DIR="/x-tools/${CT_TARGET}"
3+
CT_USE_MIRROR=y
4+
CT_MIRROR_BASE_URL="https://ci-mirrors.rust-lang.org/rustc"
5+
CT_ARCH_ARM=y
6+
CT_ARCH_ARCH="armv7-a"
7+
CT_ARCH_FPU="vfpv3-d16"
8+
CT_ARCH_FLOAT_HW=y
9+
CT_TARGET_VENDOR="unknown"
10+
CT_KERNEL_LINUX=y
11+
CT_LINUX_V_4_20=y
12+
CT_BINUTILS_V_2_32=y
13+
CT_LIBC_MUSL=y
14+
CT_MUSL_V_1_2=y
15+
CT_GCC_V_8=y
16+
CT_CC_LANG_CXX=y

src/ci/github-actions/jobs.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,9 @@ auto:
198198
- name: dist-armv7-linux
199199
<<: *job-linux-4c
200200

201+
- name: dist-armv7-linux-musl
202+
<<: *job-linux-4c
203+
201204
- name: dist-i586-gnu-i586-i686-musl
202205
<<: *job-linux-4c
203206

0 commit comments

Comments
 (0)