From 92b89b68949a1001be58fc31204bfb881bf7eb24 Mon Sep 17 00:00:00 2001 From: Patrick O'Neill Date: Thu, 11 May 2023 15:57:04 -0700 Subject: Add make-report and make-report multilib to a subset of the existing build ci jobs --- .github/setup-apt.sh | 2 +- .github/workflows/build.yaml | 58 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+), 1 deletion(-) diff --git a/.github/setup-apt.sh b/.github/setup-apt.sh index 5ce65e5..1ee5d8f 100755 --- a/.github/setup-apt.sh +++ b/.github/setup-apt.sh @@ -5,4 +5,4 @@ dpkg --add-architecture i386 apt update apt install -y autoconf automake autotools-dev curl python3 libmpc-dev libmpfr-dev \ libgmp-dev gawk build-essential bison flex texinfo gperf libtool \ - patchutils bc zlib1g-dev libexpat-dev git + patchutils bc zlib1g-dev libexpat-dev git ninja-build expect diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1139913..0a8b8d9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -36,6 +36,14 @@ jobs: ./configure --prefix=/opt/riscv --with-arch=${TARGET_TUPLE[0]} --with-abi=${TARGET_TUPLE[1]} sudo make -j $(nproc) ${{ matrix.mode }} + - name: make report + if: | + matrix.os == 'ubuntu-20.04' + && (matrix.mode == 'linux' || matrix.mode == 'newlib') + && matrix.target == 'rv64gc-lp64d' + run: | + sudo make report-${{ matrix.mode }} -j $(nproc) + - name: tarball build run: tar czvf riscv.tar.gz -C /opt/ riscv/ @@ -57,3 +65,53 @@ jobs: with: name: ${{ steps.toolchain-name-generator.outputs.TOOLCHAIN_NAME }} path: riscv.tar.gz + + build-multilib: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-20.04] + mode: [newlib, linux] + target: [rv64gc-lp64d] + steps: + - uses: actions/checkout@v2 + + - name: initialize submodules + run: | + git submodule init + git submodule update --recursive --progress --recommend-shallow + + - name: install dependencies + run: sudo ./.github/setup-apt.sh + + - name: build toolchain + run: | + TARGET_TUPLE=($(echo ${{ matrix.target }} | tr "-" "\n")) + ./configure --prefix=/opt/riscv --with-arch=${TARGET_TUPLE[0]} --with-abi=${TARGET_TUPLE[1]} --enable-multilib + sudo make -j $(nproc) ${{ matrix.mode }} + + - name: make report + run: | + sudo make report-${{ matrix.mode }} -j $(nproc) + + - name: tarball build + run: tar czvf riscv.tar.gz -C /opt/ riscv/ + + - name: generate prebuilt toolchain name + id: toolchain-name-generator + run: | + if [[ "${{ matrix.target }}" == *"32"* ]]; then BITS=32; else BITS=64; fi + case "${{ matrix.mode }}" in + "linux") + MODE="glibc";; + "musl") + MODE="musl";; + *) + MODE="elf";; + esac + echo ::set-output name=TOOLCHAIN_NAME::riscv$BITS-$MODE-${{ matrix.os }}-multilib-nightly + + - uses: actions/upload-artifact@v2 + with: + name: ${{ steps.toolchain-name-generator.outputs.TOOLCHAIN_NAME }} + path: riscv.tar.gz -- cgit v1.1