summaryrefslogtreecommitdiff
path: root/scripts/package-build/linux-kernel
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2026-11-05 17:27:50 +0000
committerChristian Breunig <christian@breunig.cc>2026-11-05 17:27:50 +0000
commit95fcbdda9a28e820f217b98c7173fe1719d16688 (patch)
tree173acaa6b4cb12990ae6e5937dd66d3e333945ae /scripts/package-build/linux-kernel
parent73f6ea2050b062f08737651980159f763d249e71 (diff)
downloadvyos-build-95fcbdda9a28e820f217b98c7173fe1719d16688.tar.gz
vyos-build-95fcbdda9a28e820f217b98c7173fe1719d16688.zip
Kernel: T9577: abort out-of-tree module builds on the first error
Several build helpers kept going after a failing command, so a broken patch, compile or signing step could still produce a package and the calling build reported success. Unsigned modules could end up in an image this way. These helpers now stop at the first error. The Mellanox OFED build also exits non-zero when not run as root instead of silently succeeding.
Diffstat (limited to 'scripts/package-build/linux-kernel')
-rwxr-xr-xscripts/package-build/linux-kernel/build-accel-ppp-ng.sh1
-rwxr-xr-xscripts/package-build/linux-kernel/build-mellanox-ofed.sh3
-rwxr-xr-xscripts/package-build/linux-kernel/sign-modules.sh1
3 files changed, 4 insertions, 1 deletions
diff --git a/scripts/package-build/linux-kernel/build-accel-ppp-ng.sh b/scripts/package-build/linux-kernel/build-accel-ppp-ng.sh
index 6e62d879..fbf22707 100755
--- a/scripts/package-build/linux-kernel/build-accel-ppp-ng.sh
+++ b/scripts/package-build/linux-kernel/build-accel-ppp-ng.sh
@@ -1,4 +1,5 @@
#!/bin/sh
+set -e
ARCH_TRIPLET=$(dpkg-architecture -qDEB_HOST_MULTIARCH)
CWD=$(pwd)
diff --git a/scripts/package-build/linux-kernel/build-mellanox-ofed.sh b/scripts/package-build/linux-kernel/build-mellanox-ofed.sh
index 76c1bd03..a8ba13e7 100755
--- a/scripts/package-build/linux-kernel/build-mellanox-ofed.sh
+++ b/scripts/package-build/linux-kernel/build-mellanox-ofed.sh
@@ -1,4 +1,5 @@
#!/bin/sh
+set -e
DROP_DEV_DBG_DEBS=1
DEB_DISTRO='debian12.1'
CWD=$(pwd)
@@ -7,7 +8,7 @@ KERNEL_VAR_FILE=${CWD}/kernel-vars
if [ $(id -u) -ne 0 ]; then
echo "Mellanox OFED script needs to be run as root"
- exit
+ exit 1
fi
require_amd64 "Mellanox OFED"
diff --git a/scripts/package-build/linux-kernel/sign-modules.sh b/scripts/package-build/linux-kernel/sign-modules.sh
index d1d822cb..90cad13a 100755
--- a/scripts/package-build/linux-kernel/sign-modules.sh
+++ b/scripts/package-build/linux-kernel/sign-modules.sh
@@ -1,4 +1,5 @@
#!/bin/sh
+set -e
BASE_DIR=$(dirname $0)
MODULE_DIR=$1