Patchwork opkg: ignore result of opkg configure

login
register
mail settings
Submitter Shakeel, Muhammad
Date Oct. 2, 2013, 3:07 p.m.
Message ID <1380726432-25519-1-git-send-email-muhammad_shakeel@mentor.com>
Download mbox | patch
Permalink /patch/59191/
State Accepted
Commit 2a013e290dcc91832c36047520259592b1d61a48
Headers show

Comments

Shakeel, Muhammad - Oct. 2, 2013, 3:07 p.m.
From: Muhammad Shakeel <muhammad_shakeel@mentor.com>

Some packages may return error while running opkg-cl configure, during
first boot. This will fail 'ExecStart' and 'ExecStartPost' will not run.
Without 'ExecStartPost' opkg-configure service will continue to run on
successive boot attempts. 'ExecStartPost' should disable this service
after first boot irrespective of 'ExecStart' status.

Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
---
 .../opkg/opkg/opkg-configure.service               |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Ross Burton - Oct. 8, 2013, 9:01 a.m.
On 2 October 2013 16:07, Shakeel, Muhammad <muhammad_shakeel@mentor.com> wrote:
> From: Muhammad Shakeel <muhammad_shakeel@mentor.com>
>
> Some packages may return error while running opkg-cl configure, during
> first boot. This will fail 'ExecStart' and 'ExecStartPost' will not run.
> Without 'ExecStartPost' opkg-configure service will continue to run on
> successive boot attempts. 'ExecStartPost' should disable this service
> after first boot irrespective of 'ExecStart' status.

Isn't there an argument that the current behaviour is right?  Whilst
there's still outstanding postinstalls to run, continue attempting to
run them.  At some point they'll hopefully succeed - the original
failure may have been an ordering problem.

Ross

Patch

diff --git a/meta/recipes-devtools/opkg/opkg/opkg-configure.service b/meta/recipes-devtools/opkg/opkg/opkg-configure.service
index a1c3a31..b18295b 100644
--- a/meta/recipes-devtools/opkg/opkg/opkg-configure.service
+++ b/meta/recipes-devtools/opkg/opkg/opkg-configure.service
@@ -7,7 +7,7 @@  Before=sysinit.target
 [Service]
 Type=oneshot
 EnvironmentFile=-@SYSCONFDIR@/default/postinst
-ExecStart=@BASE_BINDIR@/sh -c " if [ $POSTINST_LOGGING = '1' ]; then @BINDIR@/opkg-cl configure > $LOGFILE 2>&1; else @BINDIR@/opkg-cl configure; fi"
+ExecStart=-@BASE_BINDIR@/sh -c " if [ $POSTINST_LOGGING = '1' ]; then @BINDIR@/opkg-cl configure > $LOGFILE 2>&1; else @BINDIR@/opkg-cl configure; fi"
 ExecStartPost=@BASE_BINDIR@/systemctl disable opkg-configure.service
 StandardOutput=syslog
 RemainAfterExit=No