Skip to content

Commit 8c29df2

Browse files
committed
Merge branch 'master' into deploy
2 parents a63c40f + 6263b48 commit 8c29df2

13 files changed

Lines changed: 65 additions & 23 deletions

File tree

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ Different toolchains
5151

5252
There are images for various toolchains, they are encoded in the distro name/version.
5353

54+
- `korg@13.1.0`: kernel.org gcc 13.1.0, binutils 2.40
55+
- `korg@12.3.0`: kernel.org gcc 12.3.0, binutils 2.40
5456
- `korg@12.2.0`: kernel.org gcc 12.2.0, binutils 2.39
5557
- `korg@12.1.0`: kernel.org gcc 12.1.0, binutils 2.38
5658
- `korg@11.3.0`: kernel.org gcc 11.3.0, binutils 2.38
@@ -67,6 +69,7 @@ There are images for various toolchains, they are encoded in the distro name/ver
6769
- `ubuntu@20.04`: Ubuntu 20.04, gcc 9.4.0, binutils 2.34
6870
- `ubuntu@18.04`: Ubuntu 18.04, gcc 7.5.0, binutils 2.30
6971
- `ubuntu@16.04`: Ubuntu 16.04, gcc 5.4.0, binutils 2.26.1
72+
- `fedora@38`: Fedora 38, gcc 12.2.1, binutils 2.39-3, clang 16.0.2
7073
- `fedora@37`: Fedora 37, gcc 12.2.1, binutils 2.38-5, clang 15.0.7
7174
- `fedora@36`: Fedora 36, gcc 12.1.1, binutils 2.37-7, clang 14.0.5
7275
- `fedora@35`: Fedora 35, gcc 11.2.1, binutils 2.37-3, clang 13.0.1

build/Makefile

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,26 @@
11
all: help
22

3-
export FEDORA_LATEST := 37
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
3+
export FEDORA_LATEST := 38
4+
5+
x86 = $(filter x86_64,$(shell uname -m))
6+
isa_3 = $(filter arch_3_00,$(shell LD_SHOW_AUXV=1 /bin/true))
7+
8+
ifeq ($(or ${x86},${isa_3}),)
9+
# Can't use 22.04 or newer on P8
10+
export UBUNTU_LATEST := 21.10
11+
UBUNTU_DISTROS := ubuntu@${UBUNTU_LATEST}
12+
else
13+
export UBUNTU_LATEST := 22.10
14+
UBUNTU_DISTROS := ubuntu@${UBUNTU_LATEST} ubuntu@22.04
1315
endif
1416

15-
FEDORA_DISTROS := fedora@${FEDORA_LATEST} fedora@36 fedora@35 fedora@34 fedora@33 fedora@31 fedora
16-
UBUNTU_DISTROS := ubuntu@${UBUNTU_LATEST} ubuntu@20.04 ubuntu@18.04 ubuntu@16.04 ubuntu
17-
KORG_DISTROS := korg@12.2.0 korg@12.1.0 korg@11.3.0 korg@11.1.0 korg@10.3.0 korg@9.4.0 korg@9.3.0 korg@8.5.0 korg@8.1.0 korg@5.5.0
17+
UBUNTU_DISTROS += ubuntu@20.04 ubuntu@18.04 ubuntu@16.04 ubuntu
18+
19+
FEDORA_DISTROS := fedora@${FEDORA_LATEST} fedora@37 fedora@36 fedora@35 fedora@34 fedora@33 fedora@31 fedora
20+
KORG_DISTROS := korg@13.1.0 korg@12.3.0 korg@12.2.0 korg@12.1.0 korg@11.3.0 korg@11.1.0 korg@10.3.0 korg@9.4.0 korg@9.3.0 korg@8.5.0 korg@8.1.0 korg@5.5.0
1821
ALL_DISTROS := ${UBUNTU_DISTROS} ${KORG_DISTROS} ${FEDORA_DISTROS}
1922
DOCS_DISTRO := docs@${UBUNTU_LATEST}
20-
X86_DISTRO := ubuntu@${UBUNTU_LATEST}
23+
X86_DISTROS := ubuntu@${UBUNTU_LATEST} ubuntu
2124
ALIAS_DISTROS := ubuntu ubuntu-allcross fedora
2225
ALLCROSS_DISTROS := ubuntu-allcross@${UBUNTU_LATEST} ubuntu-allcross
2326
ALL_ARCHES := alpha arm arm64 i686 m68k mips mips64 riscv s390 sh sparc x86_64
@@ -83,11 +86,15 @@ endef
8386
$(eval $(call MAIN_TEMPLATE,ppc64le,${DOCS_DISTRO}))
8487
$(eval $(call DOCS_TEMPLATE,ppc64le,${DOCS_DISTRO}))
8588

86-
$(eval $(call MAIN_TEMPLATE,x86_64,${X86_DISTRO}))
87-
$(eval $(call KERNEL_TEMPLATE,x86_64,${X86_DISTRO}))
89+
$(foreach distro,${X86_DISTROS}, \
90+
$(eval $(call MAIN_TEMPLATE,x86_64,${distro})) \
91+
$(eval $(call KERNEL_TEMPLATE,x86_64,${distro})) \
92+
)
8893

8994
ifeq ($(shell uname -m),x86_64)
90-
$(eval $(call SELFTESTS_TEMPLATE,x86_64,${X86_DISTRO}))
95+
$(foreach distro,${X86_DISTROS}, \
96+
$(eval $(call SELFTESTS_TEMPLATE,x86_64,${distro})) \
97+
)
9198
endif
9299

93100
$(foreach distro,${ALL_DISTROS}, \

build/fedora/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ RUN dnf -y install --setopt=install_weak_deps=False \
3434
rsync \
3535
sparse \
3636
uboot-tools \
37+
which \
3738
xz && \
3839
dnf clean all
3940

build/korg/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ RUN apt-get -q -y update && \
2727
libssl-dev \
2828
lzop \
2929
make \
30+
python3 \
3031
openssl \
3132
u-boot-tools \
3233
rename \
@@ -53,6 +54,7 @@ RUN /tmp/make-links.sh ${compiler_version} && rm /tmp/make-links.sh
5354
ARG uid
5455
ARG gid
5556

57+
RUN userdel -r ubuntu || true
5658
RUN groupadd --gid $gid linuxppc
5759
RUN useradd --uid $uid --gid $gid linuxppc
5860
USER linuxppc

build/scripts/build.sh

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,8 @@ if [[ -n $TARGETS ]]; then
164164
cmd+="-e TARGETS=$TARGETS "
165165
fi
166166

167-
output_dir=$(get_output_dir "$script_base" "$subarch" "$distro" "$version" "$task" "$DEFCONFIG" "$TARGETS" "$CLANG")
167+
output_dir=$(get_output_dir "$script_base" "$subarch" "$distro" "$version" "$task" "$DEFCONFIG" "$TARGETS" "$CLANG" "")
168+
output_symlink=$(get_output_dir "$script_base" "$subarch" "$distro" "$version" "$task" "$DEFCONFIG" "$TARGETS" "$CLANG" "symlink")
168169
mkdir -p "$output_dir" || exit 1
169170

170171
cmd+="-v $output_dir:/output:rw "
@@ -200,6 +201,14 @@ image="linuxppc/build:$distro-$version"
200201
cmd+="$image "
201202
cmd+="/bin/container-build.sh $task"
202203

204+
echo "## output = $output_dir"
205+
203206
(set -x; $cmd)
204207

205-
exit $?
208+
ret=$?
209+
if [[ $ret -eq 0 && -n "$output_symlink" ]]; then
210+
rm -f $output_symlink
211+
ln -s $output_dir $output_symlink
212+
fi
213+
214+
exit $ret

build/scripts/clean.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ script_base="$(realpath "$dir")"
1111

1212
IFS=@ read -r task subarch distro version <<< "$1"
1313

14-
output_dir=$(get_output_dir "$script_base" "$subarch" "$distro" "$version" "$task" "$DEFCONFIG" "$TARGETS" "$CLANG")
14+
output_dir=$(get_output_dir "$script_base" "$subarch" "$distro" "$version" "$task" "$DEFCONFIG" "$TARGETS" "$CLANG" "")
1515

1616
(set -x ; rm -rf "$output_dir")

build/scripts/container-build.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,8 @@ if [[ "$1" == "kernel" ]]; then
128128

129129
echo "## Kernel build completed rc = $rc"
130130

131+
/linux/scripts/clang-tools/gen_compile_commands.py -o /output/compile_commands.json /output > /dev/null 2>&1 || true
132+
131133
if [[ -f /output/vmlinux ]]; then
132134
size /output/vmlinux
133135
fi
@@ -198,6 +200,7 @@ else
198200
(set -x; $cmd clean)
199201
fi
200202

203+
(set -x; make $quiet -j $JFACTOR headers)
201204
(set -x; $cmd)
202205
rc=$?
203206
echo "## Selftest build completed rc = $rc"

build/scripts/image.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@ elif [[ "$distro" == "korg" ]]; then
123123
# Use an older distro for the 5.x toolchains.
124124
if [[ "$version" == 5.* ]]; then
125125
from="docker.io/ubuntu:16.04"
126+
elif [[ "$version" == 13.* ]]; then
127+
from="docker.io/ubuntu:23.04"
126128
else
127129
from="docker.io/ubuntu:20.04"
128130
fi

build/scripts/lib.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ function get_output_dir()
2525
local defconfig="$6"
2626
local targets="$7"
2727
local clang="$8"
28+
local symlink="$9"
2829
local d
2930

3031
if [[ -z "$script_base" || -z "$subarch" || -z "$distro" ]]; then
@@ -41,6 +42,10 @@ function get_output_dir()
4142
case "$task" in
4243
kernel) ;&
4344
clean-kernel)
45+
if [[ -n "$symlink" ]]; then
46+
echo "$d/latest-kernel"
47+
return 0
48+
fi
4449
if [[ -n "$defconfig" ]]; then
4550
defconfig="${defconfig//\//_}"
4651
d="$d/$defconfig"
@@ -49,6 +54,10 @@ function get_output_dir()
4954
ppctests) ;&
5055
selftests) ;&
5156
clean-selftests)
57+
if [[ -n "$symlink" ]]; then
58+
echo "$d/latest-selftests"
59+
return 0
60+
fi
5261
if [[ -n "$targets" ]]; then
5362
targets=${targets// /_}
5463
targets=${targets//\//_}
@@ -59,6 +68,10 @@ function get_output_dir()
5968
;;
6069
perf) ;&
6170
clean-perf)
71+
if [[ -n "$symlink" ]]; then
72+
echo "$d/latest-perf"
73+
return 0
74+
fi
6275
d="$d/perf"
6376
;;
6477
esac
@@ -76,6 +89,7 @@ function get_output_dir()
7689
d="$d@$version"
7790
fi
7891

92+
d=$(realpath $d)
7993
echo "$d"
8094

8195
return 0
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
CONFIG_PROVE_LOCKING=y
22
CONFIG_RCU_EXPERT=y
3-
CONFIG_PROVE_RCU_LIST=y

0 commit comments

Comments
 (0)