linux-custom: add -e option to postinstall script

Message ID 20251027072854.96296-1-srinuvasan.a@siemens.com
State Under Review
Headers show
Series linux-custom: add -e option to postinstall script | expand

Commit Message

srinuvasan.a Oct. 27, 2025, 7:28 a.m. UTC
From: Srinuvasan A <srinuvasan.a@siemens.com>

While inspecting the kernel package, a warning was observed related
to the postinstall script. It appears the script was not using the
`-e` option, which ensures the script stops immediately upon any error.

To fix this warning, add the -e option to the postinstall script,
similar to how other maintainer scripts have it.

Logs:
W: linux-image-cip: maintainer-script-ignores-errors [postinst]

Signed-off-by: Srinuvasan A <srinuvasan.a@siemens.com>
---
 .../recipes-kernel/linux/files/debian/linux-image.postinst.tmpl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/meta/recipes-kernel/linux/files/debian/linux-image.postinst.tmpl b/meta/recipes-kernel/linux/files/debian/linux-image.postinst.tmpl
index 3a0d281d..72718a2c 100644
--- a/meta/recipes-kernel/linux/files/debian/linux-image.postinst.tmpl
+++ b/meta/recipes-kernel/linux/files/debian/linux-image.postinst.tmpl
@@ -1,4 +1,4 @@ 
-#!/bin/sh
+#!/bin/sh -e
 # based on https://salsa.debian.org/kernel-team/linux/blob/479cb120ecb2b3f2c4d929a7b57860248d6f79bd/debian/templates/image.postinst.in
 # SPDX-License-Identifier: GPL-2.0-only