In case a exec_postinst_scriptlets child process fails during installation we want indication that the service has a problem. Otherwise the error is disguised.
Signed-off-by: Bastian Germann <[email protected]> --- .../run-postinsts/run-postinsts/run-postinsts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts b/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts index a94a769b59..f374b05e8e 100755 --- a/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts +++ b/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts @@ -68,6 +68,10 @@ exec_postinst_scriptlets() { [ "$POSTINST_LOGGING" = "1" ] && eval echo "Running postinst $i..." $append_log if [ -x $i ]; then (sh -c $i $append_log) + if [ $? -ne 0 ]; then + echo "ERROR: postinst $i failed." + exit 1 + fi rm $i else echo "ERROR: postinst $i failed."
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#227525): https://lists.openembedded.org/g/openembedded-core/message/227525 Mute This Topic: https://lists.openembedded.org/mt/116727799/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
