Skip to content

Commit 92b89b6

Browse files
committed
Add make-report and make-report multilib to a subset of the existing build ci jobs
1 parent 95f887e commit 92b89b6

File tree

2 files changed

+59
-1
lines changed

2 files changed

+59
-1
lines changed

.github/setup-apt.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ dpkg --add-architecture i386
55
apt update
66
apt install -y autoconf automake autotools-dev curl python3 libmpc-dev libmpfr-dev \
77
libgmp-dev gawk build-essential bison flex texinfo gperf libtool \
8-
patchutils bc zlib1g-dev libexpat-dev git
8+
patchutils bc zlib1g-dev libexpat-dev git ninja-build expect

.github/workflows/build.yaml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,14 @@ jobs:
3636
./configure --prefix=/opt/riscv --with-arch=${TARGET_TUPLE[0]} --with-abi=${TARGET_TUPLE[1]}
3737
sudo make -j $(nproc) ${{ matrix.mode }}
3838
39+
- name: make report
40+
if: |
41+
matrix.os == 'ubuntu-20.04'
42+
&& (matrix.mode == 'linux' || matrix.mode == 'newlib')
43+
&& matrix.target == 'rv64gc-lp64d'
44+
run: |
45+
sudo make report-${{ matrix.mode }} -j $(nproc)
46+
3947
- name: tarball build
4048
run: tar czvf riscv.tar.gz -C /opt/ riscv/
4149

@@ -57,3 +65,53 @@ jobs:
5765
with:
5866
name: ${{ steps.toolchain-name-generator.outputs.TOOLCHAIN_NAME }}
5967
path: riscv.tar.gz
68+
69+
build-multilib:
70+
runs-on: ${{ matrix.os }}
71+
strategy:
72+
matrix:
73+
os: [ubuntu-20.04]
74+
mode: [newlib, linux]
75+
target: [rv64gc-lp64d]
76+
steps:
77+
- uses: actions/checkout@v2
78+
79+
- name: initialize submodules
80+
run: |
81+
git submodule init
82+
git submodule update --recursive --progress --recommend-shallow
83+
84+
- name: install dependencies
85+
run: sudo ./.github/setup-apt.sh
86+
87+
- name: build toolchain
88+
run: |
89+
TARGET_TUPLE=($(echo ${{ matrix.target }} | tr "-" "\n"))
90+
./configure --prefix=/opt/riscv --with-arch=${TARGET_TUPLE[0]} --with-abi=${TARGET_TUPLE[1]} --enable-multilib
91+
sudo make -j $(nproc) ${{ matrix.mode }}
92+
93+
- name: make report
94+
run: |
95+
sudo make report-${{ matrix.mode }} -j $(nproc)
96+
97+
- name: tarball build
98+
run: tar czvf riscv.tar.gz -C /opt/ riscv/
99+
100+
- name: generate prebuilt toolchain name
101+
id: toolchain-name-generator
102+
run: |
103+
if [[ "${{ matrix.target }}" == *"32"* ]]; then BITS=32; else BITS=64; fi
104+
case "${{ matrix.mode }}" in
105+
"linux")
106+
MODE="glibc";;
107+
"musl")
108+
MODE="musl";;
109+
*)
110+
MODE="elf";;
111+
esac
112+
echo ::set-output name=TOOLCHAIN_NAME::riscv$BITS-$MODE-${{ matrix.os }}-multilib-nightly
113+
114+
- uses: actions/upload-artifact@v2
115+
with:
116+
name: ${{ steps.toolchain-name-generator.outputs.TOOLCHAIN_NAME }}
117+
path: riscv.tar.gz

0 commit comments

Comments
 (0)