diff options
author | Anton Gerasimov <anton@advancedtelematic.com> | 2016-12-09 17:31:23 +0100 |
---|---|---|
committer | Anton Gerasimov <anton@advancedtelematic.com> | 2016-12-20 14:02:34 +0100 |
commit | eff667c136570fa52ed51e2c8d3c38502272b4fb (patch) | |
tree | 7d28a575bd7f3ccbd9a3f605f8f904549bcbe074 /recipes-sota | |
parent | e562aef8830c6d6e12656d9414c35b30bf78b050 (diff) | |
download | meta-updater-eff667c136570fa52ed51e2c8d3c38502272b4fb.tar.gz |
Make systemd optional
Diffstat (limited to 'recipes-sota')
-rw-r--r-- | recipes-sota/ostree/ostree_git.bb | 9 | ||||
-rw-r--r-- | recipes-sota/rvi-sota-client/rvi-sota-client_git.bb | 8 |
2 files changed, 10 insertions, 7 deletions
diff --git a/recipes-sota/ostree/ostree_git.bb b/recipes-sota/ostree/ostree_git.bb index d444669..b6adf9b 100644 --- a/recipes-sota/ostree/ostree_git.bb +++ b/recipes-sota/ostree/ostree_git.bb | |||
@@ -14,7 +14,9 @@ S = "${WORKDIR}/git" | |||
14 | 14 | ||
15 | BBCLASSEXTEND = "native" | 15 | BBCLASSEXTEND = "native" |
16 | 16 | ||
17 | DEPENDS += "attr libarchive glib-2.0 pkgconfig gpgme libgsystem fuse libsoup-2.4 e2fsprogs systemd" | 17 | DEPENDS += "attr libarchive glib-2.0 pkgconfig gpgme libgsystem fuse libsoup-2.4 e2fsprogs" |
18 | DEPENDS_append = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}" | ||
19 | |||
18 | DEPENDS_remove_class-native = "systemd-native" | 20 | DEPENDS_remove_class-native = "systemd-native" |
19 | 21 | ||
20 | RDEPENDS_${PN} = "python util-linux-libuuid util-linux-libblkid util-linux-libmount libcap xz os-release" | 22 | RDEPENDS_${PN} = "python util-linux-libuuid util-linux-libblkid util-linux-libmount libcap xz os-release" |
@@ -25,7 +27,7 @@ EXTRA_OEMAKE = "CFLAGS='-g'" | |||
25 | EXTRA_OECONF_append_class-native = " --enable-wrpseudo-compat" | 27 | EXTRA_OECONF_append_class-native = " --enable-wrpseudo-compat" |
26 | 28 | ||
27 | SYSTEMD_REQUIRED = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}" | 29 | SYSTEMD_REQUIRED = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}" |
28 | SYSTEMD_REQUIRED_class-native = "" | 30 | SYSTEMD_REQUIRED_class-native = "false" |
29 | 31 | ||
30 | SYSTEMD_SERVICE_${PN} = "ostree-prepare-root.service ostree-remount.service" | 32 | SYSTEMD_SERVICE_${PN} = "ostree-prepare-root.service ostree-remount.service" |
31 | SYSTEMD_SERVICE_${PN}_class-native = "" | 33 | SYSTEMD_SERVICE_${PN}_class-native = "" |
@@ -52,8 +54,7 @@ do_compile_prepend() { | |||
52 | export SYSTEMD_REQUIRED | 54 | export SYSTEMD_REQUIRED |
53 | 55 | ||
54 | do_install_append() { | 56 | do_install_append() { |
55 | if [ -n ${SYSTEMD_REQUIRED} ]; then | 57 | if [ "$SYSTEMD_REQUIRED" == "true" ]; then |
56 | install -p -D ${S}/src/boot/ostree-prepare-root.service ${D}${systemd_unitdir}/system/ostree-prepare-root.service | ||
57 | install -p -D ${S}/src/boot/ostree-remount.service ${D}${systemd_unitdir}/system/ostree-remount.service | 58 | install -p -D ${S}/src/boot/ostree-remount.service ${D}${systemd_unitdir}/system/ostree-remount.service |
58 | fi | 59 | fi |
59 | } | 60 | } |
diff --git a/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb b/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb index 9a7ec10..a9a9c2c 100644 --- a/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb +++ b/recipes-sota/rvi-sota-client/rvi-sota-client_git.bb | |||
@@ -21,7 +21,7 @@ FILES_${PN} = " \ | |||
21 | ${bindir}/system_info.sh \ | 21 | ${bindir}/system_info.sh \ |
22 | ${sysconfdir}/sota_client.version \ | 22 | ${sysconfdir}/sota_client.version \ |
23 | ${sysconfdir}/sota_certificates \ | 23 | ${sysconfdir}/sota_certificates \ |
24 | ${systemd_unitdir}/system/sota_client.service \ | 24 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${systemd_unitdir}/system/sota_client.service', '', d)} \ |
25 | ${bindir}/sota_ostree.sh \ | 25 | ${bindir}/sota_ostree.sh \ |
26 | " | 26 | " |
27 | 27 | ||
@@ -134,8 +134,10 @@ do_install() { | |||
134 | install -m 0755 run/system_info.sh ${D}${bindir} | 134 | install -m 0755 run/system_info.sh ${D}${bindir} |
135 | install -m 0755 run/sota_ostree.sh ${D}${bindir} | 135 | install -m 0755 run/sota_ostree.sh ${D}${bindir} |
136 | 136 | ||
137 | install -d ${D}${systemd_unitdir}/system | 137 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then |
138 | install -c ${S}/run/sota_client.service ${D}${systemd_unitdir}/system | 138 | install -d ${D}${systemd_unitdir}/system |
139 | install -c ${S}/run/sota_client.service ${D}${systemd_unitdir}/system | ||
140 | fi | ||
139 | 141 | ||
140 | install -d ${D}${sysconfdir} | 142 | install -d ${D}${sysconfdir} |
141 | install -c ${S}/run/sota_certificates ${D}${sysconfdir} | 143 | install -c ${S}/run/sota_certificates ${D}${sysconfdir} |