01/02: systemd-compat-units: pkg_postinst() does not work
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 47 lines · On Thu, Aug 18, 2016 at 03:52:33PM +0000, [email protected] wrote:
rpurdie pushed a commit to branch master
in repository openembedded-core.commit
8183309080aee45746daaff46b0506b09b5bd269
Author: Joe Slater <[email protected]>
AuthorDate: Mon Aug 15 16:04:53 2016 -0700systemd-compat-units:
pkg_postinst()does not workThe test for various files is wrong and will always be true, even if init.d does not exist.
Exit if init.d does not exist, and correctly test for file existence otherwise.
Signed-off-by Joe Slater <[email protected]>Signed-off-by Ross Burton <[email protected]>--- meta/recipes-core/systemd/systemd-compat-units.bb | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-)meta/recipes-core/systemd/systemd-compat-units.bb +5
-5@@ -23,21 +23,24 @@ SYSTEMD_DISABLED_SYSV_SERVICES = " \ " pkg_postinst_${PN} () { - cd $D${sysconfdir}/init.d - echo "Disabling the following sysv scripts: " + cd $D${sysconfdir}/init.d || exit 0 - OPTS="" + echo "Disabling the following sysv scripts: " if [ -n "$D" ]; then OPTS="--root=$D" + else + OPTS="" fi for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do - if [ \( -e $i -o $i.sh \) -a ! \( -e $D${sysconfdir}/systemd/system/$i.service -o -e $D${systemd_unitdir}/system/$i.service \) ] ; then - echo -n "$i: " ; systemctl ${OPTS} mask $i.service + if [ -e $i -o -e $i.sh ] && ! [ -e $D${sysconfdir}/systemd/system/$i.service -o -e $D${systemd_unitdir}/system/$i.service ] ; then
meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 46
Quoted 10 lines
meta/recipes-core/systemd/systemd-compat-units.bb +5
-2+ echo -n "$i: " + systemctl $OPTS mask $i.service fi - done ; echo + done + echo } -RDPEPENDS_${PN} = "systemd" +RDEPENDS_${PN} = "systemd"
This is good typo fix, but also causes allarch systemd-compat-units to RDEPENDS on TUNE_PKGARCH systemd as reported in:
http://lists.openembedded.org/pipermail/openembedded-core/2016-August/125483.html
So either please exclude it in layer.conf for drop this runtime dependency completely.
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
At the cost of a little build time, I guess we could lose the inherit allarch. As a practical matter, we could get rid of the RDEPEND (or make it a DEPEND?), but that seems wrong, somehow.
Joe
Quoted 79 lines
-----Original Message-----
From: Martin Jansa [mailto:[email protected]]
Sent: Monday, August 22, 2016 7:21 AM
To: [email protected]; Slater, Joseph
Cc: [email protected]
Subject: Re: [oe-commits] [openembedded-core] 01/02: systemd-compat-units:pkg_postinst()does not workmeta/recipes-
Quoted 22 lines · On Thu, Aug 18, 2016 at 03:52:33PM +0000, [email protected] wrote:
rpurdie pushed a commit to branch master
in repository openembedded-core.commit
8183309080aee45746daaff46b0506b09b5bd269
Author: Joe Slater <[email protected]>
AuthorDate: Mon Aug 15 16:04:53 2016 -0700systemd-compat-units:
pkg_postinst()does not workThe test for various files is wrong and will always be true, even if init.d does not exist.
Exit if init.d does not exist, and correctly test for file existence otherwise.
Signed-off-by Joe Slater <[email protected]>Signed-off-by Ross Burton <[email protected]>--- meta/recipes-core/systemd/systemd-compat-units.bb | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-)meta/recipes- renamed from meta/recipes-core/systemd/systemd-compat-units.bb +0
-0core/systemd/systemd-compat-units.bb
Quoted 13 lines
index 0b8ff09..90811da 100644
meta/recipes-core/systemd/systemd-compat-units.bb +1
-3@@ -23,21 +23,24 @@ SYSTEMD_DISABLED_SYSV_SERVICES = " \ " pkg_postinst_${PN} () { - cd $D${sysconfdir}/init.d - echo "Disabling the following sysv scripts: " + cd $D${sysconfdir}/init.d || exit 0 - OPTS=""meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 37
Quoted 10 lines
meta/recipes-core/systemd/systemd-compat-units.bb +3
-1+ echo "Disabling the following sysv scripts: " if [ -n "$D" ]; then OPTS="--root=$D" + else + OPTS="" fi for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do - if [ \( -e $i -o $i.sh \) -a ! \( -e $D${sysconfdir}/systemd/system/$i.service -o -e $D${systemd_unitdir}/system/$i.service \) ] ; then
meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 38
Quoted 2 lines
meta/recipes-core/systemd/systemd-compat-units.bb +1
-1- echo -n "$i: " ; systemctl ${OPTS} mask $i.service + if [ -e $i -o -e $i.sh ] && ! [ -e $D${sysconfdir}/systemd/system/$i.service-o -e $D${systemd_unitdir}/system/$i.service ] ; then
meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 46
Quoted 10 lines
meta/recipes-core/systemd/systemd-compat-units.bb +5
-2+ echo -n "$i: " + systemctl $OPTS mask $i.service fi - done ; echo + done + echo } -RDPEPENDS_${PN} = "systemd" +RDEPENDS_${PN} = "systemd"This is good typo fix, but also causes allarch systemd-compat-units to RDEPENDS on
TUNE_PKGARCHsystemd as reported in:
http://lists.openembedded.org/pipermail/openembedded-core/2016-August/125483.htmlSo either please exclude it in layer.conf for drop this runtime dependency completely.
--
Martin 'JaMa' Jansa jabber: [email protected]
changing it to DEPEND would only make it worse an more useless
Quoted 95 lines · Joseph
At the cost of a little build time, I guess we could lose the inherit allarch.
As a practical matter, we could get rid of the RDEPEND (or make it a DEPEND?),
but that seems wrong, somehow.Joe
Quoted 6 lines
-----Original Message-----
From: Martin Jansa [mailto:[email protected]]
Sent: Monday, August 22, 2016 7:21 AM
To: [email protected]; Slater, Joseph
Cc: [email protected]
Subject: Re: [oe-commits] [openembedded-core] 01/02:systemd-compat-units:
pkg_postinst()Quoted 3 lines
does not work
On Thu, Aug 18, 2016 at 03:52:33PM +0000, [email protected]
Quoted 12 lines · wrote:
Quoted 12 lines
rpurdie pushed a commit to branch master
in repository openembedded-core.commit
8183309080aee45746daaff46b0506b09b5bd269
Author: Joe Slater <[email protected]>
AuthorDate: Mon Aug 15 16:04:53 2016 -0700systemd-compat-units:
pkg_postinst()does not workThe test for various files is wrong and will always be true, even if init.d does not exist.
Quoted 7 lines
Quoted 7 lines
Exit if init.d does not exist, and correctly test for file existence otherwise.
Signed-off-by Joe Slater <[email protected]>Signed-off-by Ross Burton <[email protected]>--- meta/recipes-core/systemd/systemd-compat-units.bb | 17++++++++++-------
Quoted 3 lines
Review
Quoted 3 lines
1 file changed, 10 insertions(+), 7 deletions(-)(quoted diff) +0
-0b/meta/recipes-
Quoted 16 lines
core/systemd/systemd-compat-units.bb
Quoted 15 lines
index 0b8ff09..90811da 100644
meta/recipes-core/systemd/systemd-compat-units.bb +2
-3@@ -23,21 +23,24 @@ SYSTEMD_DISABLED_SYSV_SERVICES = " \ " pkg_postinst_${PN} () { - cd $D${sysconfdir}/init.d - echo "Disabling the following sysv scripts: " + cd $D${sysconfdir}/init.d || exit 0 - OPTS="" + echo "Disabling the following sysv scripts: "Quoted 8 lines
meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 37
Quoted 8 lines
meta/recipes-core/systemd/systemd-compat-units.bb +2
-1if [ -n "$D" ]; then OPTS="--root=$D" + else + OPTS="" fi for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do - if [ \( -e $i -o $i.sh \) -a ! \( -e$D${sysconfdir}/systemd/system/$i.service -
Quoted 3 lines
o -e $D${systemd_unitdir}/system/$i.service \) ] ; then
Quoted 2 lines
meta/recipes-core/systemd/systemd-compat-units.bb +1
-1- echo -n "$i: " ; systemctl ${OPTS} mask $i.service + if [ -e $i -o -e $i.sh ] && ! [ -e$D${sysconfdir}/systemd/system/$i.service
Quoted 9 lines
-o -e $D${systemd_unitdir}/system/$i.service ] ; then
Quoted 8 lines
meta/recipes-core/systemd/systemd-compat-units.bb +4
-1+ echo -n "$i: " + systemctl $OPTS mask $i.service fi - done ; echo + done + echo }Quoted 6 lines
meta/recipes-core/systemd/systemd-compat-units.bb SYSTEMD_DISABLED_SYSV_SERVICES = " \ · line 46
Quoted 2 lines
meta/recipes-core/systemd/systemd-compat-units.bb +1
-1-RDPEPENDS_${PN} = "systemd" +RDEPENDS_${PN} = "systemd"This is good typo fix, but also causes allarch systemd-compat-units to RDEPENDS on
TUNE_PKGARCHsystemd as reported in:
http://lists.openembedded.org/pipermail/openembedded-core/2016-August/125483.html
Quoted 6 lines
So either please exclude it in layer.conf for drop this runtime dependency completely.
--
Martin 'JaMa' Jansa jabber: [email protected]