Skip to content

Commit 8f39f48

Browse files
committed
Use manylinux2014 for building toolchain
This allows the artifact to run on CentOS 7.
1 parent 89209fc commit 8f39f48

File tree

2 files changed

+29
-3
lines changed

2 files changed

+29
-3
lines changed

.github/workflows/toolchain_build.yml

+27-3
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,40 @@ jobs:
4242
# output_dir: /opt/riscv-linux-toolchain
4343

4444
name: ${{ matrix.display_name }}
45-
runs-on: ubuntu-20.04
45+
runs-on: ubuntu-latest
46+
# This is a CentOS 7 based image
47+
container: quay.io/pypa/manylinux2014_x86_64
4648
timeout-minutes: 360
4749

4850
steps:
49-
- uses: actions/checkout@v4
51+
# This uses checkout v3 instead of v4 because GitHub actions's nodejs 20 currently does not work on CentOS 7.
52+
- uses: actions/checkout@v3
5053

5154
- name: Setup environment
5255
run: |
5356
echo ::group::Install dependencies
54-
./prepare-ubuntu-20.04.sh
57+
yum install -y \
58+
sudo \
59+
git \
60+
shadow-utils \
61+
bison \
62+
flex \
63+
texinfo \
64+
help2man \
65+
gawk \
66+
gettext \
67+
curl \
68+
xz \
69+
ncurses-devel \
70+
ncurses-static \
71+
pixman-devel \
72+
rh-python36 \
73+
zlib-devel \
74+
zlib-static \
75+
libffi-devel
76+
echo ::endgroup::
77+
78+
echo ::group::Install crosstool-ng
5579
./install-crosstool-ng.sh
5680
echo ::endgroup::
5781

build-gcc-with-args.sh

+2
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,8 @@ cd "${build_top_dir}/build/gcc"
6464
echo "# ADDED BY ${0}";
6565
echo "CT_PREFIX_DIR=\"${toolchain_dest}\""
6666
echo "CT_LOCAL_PATCH_DIR=\"${build_top_dir}/patches/${toolchain_name}\""
67+
echo "CT_ALLOW_BUILD_AS_ROOT=y"
68+
echo "CT_ALLOW_BUILD_AS_ROOT_SURE=y"
6769
echo "# END ADDED BY ${0}"
6870
} > .config
6971
ct-ng upgradeconfig

0 commit comments

Comments
 (0)