Skip to content

Commit ea3bfae

Browse files
committed
Add Ubuntu 22.04 as the new default on Power9 or later
Make Ubuntu 22.04 the new default, but it is built for Power9 or later and the images SIGILL when run on earlier CPUs. So if we're on Power8 or eariler fall back to 21.10.
1 parent ebeb581 commit ea3bfae

3 files changed

Lines changed: 14 additions & 3 deletions

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ There are images for various toolchains, they are encoded in the distro name/ver
5656
- kernel.org gcc 9.3.0 `korg@9.3.0`
5757
- kernel.org gcc 8.1.0 `korg@8.1.0`
5858
- kernel.org gcc 5.5.0 `korg@5.5.0`
59+
- Ubuntu 22.04 `ubuntu@22.04`
5960
- Ubuntu 21.10 `ubuntu@21.10`
6061
- Ubuntu 21.04 `ubuntu@21.04`
6162
- Ubuntu 20.04 `ubuntu@20.04`

build/Makefile

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,20 @@
11
all: help
22

33
export FEDORA_LATEST := 35
4-
export UBUNTU_LATEST := 21.10
4+
export UBUNTU_LATEST := 22.04
5+
6+
# If we're on ppc64le
7+
ifeq ($(shell uname -m),ppc64le)
8+
# And we don't see ISA v3.0
9+
ifeq ($(shell LD_SHOW_AUXV=1 /bin/true | grep "AT_HWCAP2:.*\barch_3_00\b"),)
10+
# Then we can't use 22.04
11+
UBUNTU_LATEST := 21.10
12+
endif
13+
endif
514

615
FEDORA_DISTROS := fedora@${FEDORA_LATEST} fedora@34 fedora@33 fedora@31 fedora
7-
UBUNTU_DISTROS := ubuntu@${UBUNTU_LATEST} ubuntu@21.04 ubuntu@20.04 ubuntu@18.04 ubuntu@16.04 ubuntu)
16+
# Sort is to elimiate duplicates if UBUNTU_LATEST == 21.10
17+
UBUNTU_DISTROS := $(sort ubuntu@${UBUNTU_LATEST} ubuntu@21.10 ubuntu@21.04 ubuntu@20.04 ubuntu@18.04 ubuntu@16.04 ubuntu)
818
KORG_DISTROS := korg@11.1.0 korg@10.3.0 korg@9.3.0 korg@8.1.0 korg@5.5.0
919
ALL_DISTROS := ${UBUNTU_DISTROS} ${KORG_DISTROS} ${FEDORA_DISTROS}
1020
DOCS_DISTRO := docs@${UBUNTU_LATEST}

build/ubuntu/packages.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if [[ "$machine" == "ppc64le" ]]; then
2222
PACKAGES+=" libmount-dev"
2323

2424
# For the x86_64 container
25-
if [[ "$VERSION_ID" == "21.10" ]]; then
25+
if [[ "$major" -ge 21 ]]; then
2626
PACKAGES+=" crossbuild-essential-amd64"
2727
fi
2828
else

0 commit comments

Comments
 (0)