[oe] [meta-oe][PATCH 09/12] systemd-compat-units: move list of disabled services to variable, fix hwclock.sh and output
Martin Jansa
martin.jansa at gmail.com
Mon Aug 6 14:33:06 UTC 2012
On Mon, Aug 06, 2012 at 04:25:58PM +0200, Koen Kooi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Op 06-08-12 15:37, Martin Jansa schreef:
> > * variable allows to add items in .bbappend without overwritting whole
> > postinst * hwclock.service should be used to blacklist SYSV hwclock.sh
> > (not hwclock.sh.service) * show only newly disabled SYSV scripts
> >
> > Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com> ---
> > .../recipes-core/systemd/systemd-compat-units.bb | 19
> > ++++++++++++++----- 1 files changed, 14 insertions(+), 5 deletions(-)
> >
> > diff --git a/meta-systemd/recipes-core/systemd/systemd-compat-units.bb
> > b/meta-systemd/recipes-core/systemd/systemd-compat-units.bb index
> > c9a6b67..2973208 100644 ---
> > a/meta-systemd/recipes-core/systemd/systemd-compat-units.bb +++
> > b/meta-systemd/recipes-core/systemd/systemd-compat-units.bb @@ -3,7 +3,7
> > @@ DESCRIPTION = "Units to make systemd work better with existing
> > sysvinit scripts" LICENSE = "MIT" LIC_FILES_CHKSUM =
> > "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
> >
> > -PR = "r15" +PR = "r16"
> >
> > inherit allarch
> >
> > @@ -26,15 +26,24 @@ do_install() { chmod 0755 ${D}${bindir}/runlevel }
> >
> > +SYSTEMD_DISABLED_SYSV_SERVICES = " \ + busybox-udhcpc \ + dnsmasq \ +
> > hwclock \ + networking \ + syslog \ + syslog.busybox \ +" +
> > pkg_postinst_${PN} () { cd $D${sysconfdir}/init.d
> >
> > echo -n "Disabling the following sysv scripts: "
> >
> > -for i in busybox-udhcpc dnsmasq hwclock.sh networking syslog
> > syslog.busybox ; do - if [ -e $i ] ; then - echo -n "$i " ; ln -s
> > /dev/null $D${systemd_unitdir}/system/$i.service - fi +for i in
> > ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do + if [ \( -e $i -o $i.sh \) -a
> > ! -e $D${base_libdir}/systemd/system/$i.service ] ; then + echo -n
> > "$i " ; ln -s /dev/null $D${base_libdir}/systemd/system/$i.service +
> > fi done ; echo }
>
> Doing something like this should work a bit better:
>
> for i in ${SYSTEMD_DISABLED_SYSV_SERVICES} ; do
> systemctl mask $i
> done
Thanks for info.
It needs .service suffis so
systemctl mask $i.service
and I'll send v2 after testing if this works also in do_rootfs time.
Or you can merge this pull request and I'll send thich change as
follow-up after testing.
Cheers,
--
Martin 'JaMa' Jansa jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-devel/attachments/20120806/c2108e83/attachment-0002.sig>
More information about the Openembedded-devel
mailing list