summaryrefslogtreecommitdiffstats
path: root/meta-sota/recipes-sota/ostree/ostree_git.bb
diff options
context:
space:
mode:
authorLeon Anavi <leon.anavi@konsulko.com>2016-07-15 18:01:44 +0300
committerLeon Anavi <leon.anavi@konsulko.com>2016-07-15 18:01:44 +0300
commitcc06610fc964769651b7888c0dde7645779f3990 (patch)
tree4c8eb82b4c297e35e35a35eb177aeb0eb10e014e /meta-sota/recipes-sota/ostree/ostree_git.bb
parent796b6ed7f1060fe23ed2391caf7946df5cb58446 (diff)
ostree: systemd services
Ensure that systemd services ostree-prepare-root and ostree-remount are installed and deployed. Change-Id: I5774ade1278cb1429c583a21066c51432d0c1a2a Signed-off-by: Leon Anavi <leon.anavi@konsulko.com>
Diffstat (limited to 'meta-sota/recipes-sota/ostree/ostree_git.bb')
-rw-r--r--meta-sota/recipes-sota/ostree/ostree_git.bb18
1 files changed, 17 insertions, 1 deletions
diff --git a/meta-sota/recipes-sota/ostree/ostree_git.bb b/meta-sota/recipes-sota/ostree/ostree_git.bb
index 57f03d4..760dd32 100644
--- a/meta-sota/recipes-sota/ostree/ostree_git.bb
+++ b/meta-sota/recipes-sota/ostree/ostree_git.bb
@@ -2,6 +2,8 @@ SUMMARY = "Tool for managing bootable, immutable, versioned filesystem trees"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
+inherit autotools-brokensep pkgconfig systemd
+
SRC_URI = "gitsm://github.com/ostreedev/ostree.git;branch=master"
SRCREV="v2016.7"
@@ -11,7 +13,8 @@ DEPENDS += "attr libarchive glib-2.0 pkgconfig gpgme libgsystem fuse libsoup-2.4
RDEPENDS_${PN} = "python libsystemd util-linux-libuuid util-linux-libblkid util-linux-libmount libcap liblzma"
-inherit autotools-brokensep
+PACKAGECONFIG ??= "${@base_contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}"
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,,,"
EXTRA_OECONF = "--with-libarchive --disable-gtk-doc --disable-gtk-doc-html --disable-gtk-doc-pdf --disable-man"
@@ -23,3 +26,16 @@ do_configure() {
NOCONFIGURE=true ./autogen.sh
oe_runconf
}
+
+do_install_append() {
+ if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+ install -p -D ${S}/src/boot/ostree-prepare-root.service ${D}${systemd_unitdir}/system/ostree-prepare-root.service
+ install -p -D ${S}/src/boot/ostree-remount.service ${D}${systemd_unitdir}/system/ostree-remount.service
+ fi
+}
+
+SYSTEMD_SERVICE_${PN} = "ostree-prepare-root.service ostree-remount.service"
+FILES_${PN} += " \
+ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/', '', d)} \
+ ${libdir}/dracut/ \
+"