Skip to content

Commit 4cc2143

Browse files
committed
init_build_environment: enable backport toolchain for buster
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
1 parent c4596b2 commit 4cc2143

File tree

2 files changed

+15
-16
lines changed

2 files changed

+15
-16
lines changed

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
1.7K May 8 2024 convert_translation.sh
2121
3.0K May 8 2024 create_acl_for_luci.sh
2222
3.7K May 8 2024 create_ucitrack_for_luci.sh
23-
14K Sep 13 17:32 init_build_environment.sh
23+
14K Sep 13 17:38 init_build_environment.sh
2424
18K Jun 1 2023 LICENSE
2525
4.0K Feb 6 2025 maintainer-tools
2626
4.7K Feb 6 2025 maketag.sh

init_build_environment.sh

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -38,57 +38,54 @@ function check_system() {
3838
NODE_KEY="nodesource.gpg.key"
3939
NODE_VERSION="18"
4040
UBUNTU_CODENAME="$VERSION_CODENAME"
41-
VERSION_PACKAGE="lib32gcc-s1 libpython3.6-dev python2.7 python3.6"
41+
VERSION_PACKAGE="libpython3.6-dev python2.7 python3.6"
4242
;;
4343
"buster")
4444
DISTRO_PREFIX="debian-archive/"
4545
DISTRO_SECUTIRY_PATH="buster/updates"
46-
GCC_VERSION="8"
46+
GCC_VERSION="9"
4747
LLVM_VERSION="18"
4848
UBUNTU_CODENAME="bionic"
49-
VERSION_PACKAGE="lib32gcc1 python2"
49+
VERSION_PACKAGE="python2"
5050
;;
5151
"focal")
5252
GCC_VERSION="9"
5353
LLVM_VERSION="18"
5454
UBUNTU_CODENAME="$VERSION_CODENAME"
55-
VERSION_PACKAGE="lib32gcc-s1 python2"
55+
VERSION_PACKAGE="python2"
5656
;;
5757
"bullseye")
5858
BPO_FLAG="-t $VERSION_CODENAME-backports"
5959
BPO_DISTRO_PREFIX="debian-archive/"
6060
GCC_VERSION="10"
6161
LLVM_VERSION="18"
6262
UBUNTU_CODENAME="focal"
63-
VERSION_PACKAGE="lib32gcc-s1 python2"
63+
VERSION_PACKAGE="python2"
6464
;;
6565
"jammy")
6666
GCC_VERSION="10"
6767
LLVM_VERSION="18"
6868
UBUNTU_CODENAME="$VERSION_CODENAME"
69-
VERSION_PACKAGE="lib32gcc-s1 python2"
69+
VERSION_PACKAGE="python2"
7070
;;
7171
"bookworm")
7272
APT_COMP="non-free-firmware"
7373
BPO_FLAG="-t $VERSION_CODENAME-backports"
7474
GCC_VERSION="12"
7575
LLVM_VERSION="18"
7676
UBUNTU_CODENAME="jammy"
77-
VERSION_PACKAGE="lib32gcc-s1"
7877
;;
7978
"noble")
8079
GCC_VERSION="13"
8180
LLVM_VERSION="18"
8281
UBUNTU_CODENAME="$VERSION_CODENAME"
83-
VERSION_PACKAGE="lib32gcc-s1"
8482
;;
8583
"trixie")
8684
APT_COMP="non-free-firmware"
8785
BPO_FLAG="-t $VERSION_CODENAME-backports"
8886
GCC_VERSION="13"
8987
LLVM_VERSION="18"
9088
UBUNTU_CODENAME="noble"
91-
VERSION_PACKAGE="lib32gcc-s1"
9289
;;
9390
*)
9491
__error_msg "Unsupported OS, use Ubuntu 20.04 instead."
@@ -182,13 +179,15 @@ function update_apt_source() {
182179
EOF
183180
curl -fsL "https://dl.yarnpkg.com/debian/pubkey.gpg" -o "/etc/apt/trusted.gpg.d/yarn.asc"
184181

185-
if [ "$VERSION_CODENAME" == "bionic" ]; then
182+
case "$VERSION_CODENAME" in
183+
"bionic"|"buster")
186184
cat <<-EOF >"/etc/apt/sources.list.d/gcc-toolchain.list"
187185
deb https://ppa.launchpadcontent.net/ubuntu-toolchain-r/test/ubuntu $UBUNTU_CODENAME main
188186
deb-src https://ppa.launchpadcontent.net/ubuntu-toolchain-r/test/ubuntu $UBUNTU_CODENAME main
189187
EOF
190188
curl -fsL "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x1e9377a2ba9ef27f" -o "/etc/apt/trusted.gpg.d/gcc-toolchain.asc"
191-
fi
189+
;;
190+
esac
192191

193192
cat <<-EOF >"/etc/apt/sources.list.d/git-core-ubuntu-ppa.list"
194193
deb https://ppa.launchpadcontent.net/git-core/ppa/ubuntu $UBUNTU_CODENAME main
@@ -243,10 +242,10 @@ function install_dependencies() {
243242
apt install -y $BPO_FLAG ack antlr3 asciidoc autoconf automake autopoint binutils bison \
244243
build-essential bzip2 ccache cmake cpio curl device-tree-compiler ecj fakeroot \
245244
fastjar flex gawk gettext genisoimage gnutls-dev gperf haveged help2man intltool \
246-
irqbalance jq libc6-dev-i386 libelf-dev libglib2.0-dev libgmp3-dev libltdl-dev \
247-
libmpc-dev libmpfr-dev libncurses-dev libreadline-dev libssl-dev libtool \
248-
libyaml-dev libz-dev lrzsz msmtp nano ninja-build p7zip p7zip-full patch pkgconf \
249-
libpython3-dev python3 python3-pip python3-cryptography python3-docutils \
245+
irqbalance jq lib32gcc-s1 libc6-dev-i386 libelf-dev libglib2.0-dev libgmp3-dev \
246+
libltdl-dev libmpc-dev libmpfr-dev libncurses-dev libreadline-dev libssl-dev \
247+
libtool libyaml-dev libz-dev lrzsz msmtp nano ninja-build p7zip p7zip-full patch \
248+
pkgconf libpython3-dev python3 python3-pip python3-cryptography python3-docutils \
250249
python3-ply python3-pyelftools python3-requests qemu-utils quilt re2c rsync scons \
251250
sharutils squashfs-tools subversion swig texinfo uglifyjs unzip vim wget xmlto \
252251
zlib1g-dev zstd xxd $VERSION_PACKAGE

0 commit comments

Comments
 (0)