[oe-commits] Koen Kooi : systemd-compat-units: package to fixup the rootfs, shouldn' t be needed in the future

git version control git at git.openembedded.org
Tue May 31 14:09:03 UTC 2011


Module: meta-openembedded.git
Branch: master
Commit: 658bd7ef32390e5d364fb41ba93363b5ee8eeb3b
URL:    http://git.openembedded.org/?p=meta-openembedded.git&a=commit;h=658bd7ef32390e5d364fb41ba93363b5ee8eeb3b

Author: Koen Kooi <koen at dominion.thruhere.net>
Date:   Tue May 31 14:37:10 2011 +0200

systemd-compat-units: package to fixup the rootfs, shouldn't be needed in the future

Signed-off-by: Koen Kooi <koen at dominion.thruhere.net>

---

 .../recipes-core/systemd/systemd-compat-units.bb   |   31 ++++++++++++++++++++
 .../systemd/systemd-compat-units/opkg.service      |   10 ++++++
 2 files changed, 41 insertions(+), 0 deletions(-)

diff --git a/meta-oe/recipes-core/systemd/systemd-compat-units.bb b/meta-oe/recipes-core/systemd/systemd-compat-units.bb
new file mode 100644
index 0000000..6fc040f
--- /dev/null
+++ b/meta-oe/recipes-core/systemd/systemd-compat-units.bb
@@ -0,0 +1,31 @@
+DESCRIPTION = "Units to make systemd work better with existing sysvinit scripts"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
+
+inherit allarch
+
+SRC_URI = "file://opkg.service"
+
+do_install() {
+	install -d ${D}${base_libdir}/systemd/system/basic.target.wants
+	install -m 0644 ${WORKDIR}/opkg.service ${D}${base_libdir}/systemd/system
+	ln -sf ../opkg.service ${D}${base_libdir}/systemd/system/basic.target.wants/
+}
+
+pkg_postinst_${PN} () {
+cd $D${sysconfdir}/init.d
+
+echo -n "Disabling the following sysv scripts: "
+
+for i in busybox-udhcpc dnsmasq hwclock.sh syslog syslog.busybox ; do
+	if [ -e $i ] ; then
+		echo -n "$i " ; ln -s /dev/null $D${base_libdir}/systemd/system/$i.service
+	fi
+done ; echo
+}
+
+FILES_${PN} = "${base_libdir}/systemd/system"
+RDPEPENDS_${PN} = "systemd"
+
+
diff --git a/meta-oe/recipes-core/systemd/systemd-compat-units/opkg.service b/meta-oe/recipes-core/systemd/systemd-compat-units/opkg.service
new file mode 100644
index 0000000..c346e57
--- /dev/null
+++ b/meta-oe/recipes-core/systemd/systemd-compat-units/opkg.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Opkg first boot configure
+ConditionPathExists=|/etc/rcS.d/S98configure
+
+[Service]
+ExecStart=/etc/rcS.d/S98configure
+RemainAfterExit=no
+
+[Install]
+WantedBy=basic.target





More information about the Openembedded-commits mailing list