summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/systemd/systemd_219.bb
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2015-09-06 15:25:40 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-09-12 22:48:23 +0100
commit68147678dd8855636b2c67789e9f2c3f21f42433 (patch)
treebbd64a15912a801be10758b293c08586ea21ba07 /meta/recipes-core/systemd/systemd_219.bb
parent21fffdeea3ac5a84dcfc753665cb1df4625c0b2a (diff)
downloadpoky-68147678dd8855636b2c67789e9f2c3f21f42433.tar.gz
systemd: Upgrade 219 -> 225
Drop patches that were straight backports from upstream MIT licence was unused and dropped from systemd sources for more details see https://github.com/systemd/systemd/commit/8f1e0c5f38cdf7e401ab4d2bb93ad816d08e7715 Drop gtkdoc dependency since libudev API documentation has been converted from gtkdoc into man pages Remove packaging gudev as it has moved to separate repository outside systemd For more details see https://github.com/systemd/systemd/commit/2375607039517c88df51ef16ddbb624ec1c10654 package newly added script for xorg to be usable with systemd --user intance For more details see https://github.com/systemd/systemd/commit/1401ec2d34bcde406ced531a72dc46ebaf332594 machinectl now has shell support private-zone DHCP options are supported by systemd-networkd For complete differences between two releases run git log --oneline v219..v225 in systemd git clone Change-Id: I998e652382950a3c74c4839f3767ef8bef23d88f (From OE-Core rev: ec2770b0d1d562ff6d5736e056f937fa24c67b10) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/systemd/systemd_219.bb')
-rw-r--r--meta/recipes-core/systemd/systemd_219.bb420
1 files changed, 0 insertions, 420 deletions
diff --git a/meta/recipes-core/systemd/systemd_219.bb b/meta/recipes-core/systemd/systemd_219.bb
deleted file mode 100644
index a64dbac360..0000000000
--- a/meta/recipes-core/systemd/systemd_219.bb
+++ /dev/null
@@ -1,420 +0,0 @@
1SUMMARY = "A System and service manager"
2HOMEPAGE = "http://www.freedesktop.org/wiki/Software/systemd"
3
4DESCRIPTION = "systemd is a system and service manager for Linux, compatible with \
5SysV and LSB init scripts. systemd provides aggressive parallelization \
6capabilities, uses socket and D-Bus activation for starting services, \
7offers on-demand starting of daemons, keeps track of processes using \
8Linux cgroups, supports snapshotting and restoring of the system \
9state, maintains mount and automount points and implements an \
10elaborate transactional dependency-based service control logic. It can \
11work as a drop-in replacement for sysvinit."
12
13LICENSE = "GPLv2 & LGPLv2.1 & MIT"
14LIC_FILES_CHKSUM = "file://LICENSE.GPL2;md5=751419260aa954499f7abaabaa882bbe \
15 file://LICENSE.LGPL2.1;md5=4fbd65380cdd255951079008b364516c \
16 file://LICENSE.MIT;md5=544799d0b492f119fa04641d1b8868ed"
17
18PROVIDES = "udev"
19
20PE = "1"
21
22DEPENDS = "kmod docbook-sgml-dtd-4.1-native intltool-native gperf-native acl readline dbus libcap libcgroup glib-2.0 qemu-native util-linux"
23
24SECTION = "base/shell"
25
26inherit gtk-doc useradd pkgconfig autotools perlnative update-rc.d update-alternatives qemu systemd ptest gettext
27
28SRCREV = "85a6fabdd3e43cfab0fc6359e9f2a9e368d4a3ed"
29
30PV = "219-stable+git${SRCPV}"
31
32SRC_URI = "git://github.com/systemd/systemd-stable;branch=v219-stable;protocol=git \
33 file://0002-shared-missing.h-fall-back-to-insecure-getenv.patch \
34 file://0003-binfmt-Don-t-install-dependency-links-at-install-tim.patch \
35 file://0004-configure-Check-for-additional-features-that-uclibc-.patch \
36 file://0005-nspawn-Use-execvpe-only-when-libc-supports-it.patch \
37 file://0006-journal-Use-posix-fallocate-only-if-available.patch \
38 file://0007-util-Use-mkostemp-only-if-libc-supports-it.patch \
39 file://0008-util-bypass-unimplemented-_SC_PHYS_PAGES-system-conf.patch \
40 file://0009-sysv-generator-add-support-for-executing-scripts-und.patch \
41 file://0010-Make-root-s-home-directory-configurable.patch \
42 file://0011-systemd-user-avoid-using-system-auth.patch \
43 file://0012-systemd-tmpfiles.c-Honor-ordering-within-files-as-th.patch \
44 file://0014-Revert-rules-remove-firmware-loading-rules.patch \
45 file://0015-Revert-udev-remove-userspace-firmware-loading-suppor.patch \
46 file://tmpfiles-pam.patch \
47 file://0001-Revert-core-mount-add-dependencies-to-dynamically-mo.patch \
48 file://touchscreen.rules \
49 file://00-create-volatile.conf \
50 file://init \
51 file://run-ptest \
52 "
53SRC_URI_append_qemuall = "file://qemuall_io_latency-core-device.c-Change-the-default-device-timeout-to-2.patch"
54
55S = "${WORKDIR}/git"
56
57SRC_URI_append_libc-uclibc = "\
58 file://0001-units-Prefer-getty-to-agetty-in-console-setup-system.patch \
59 "
60LDFLAGS_append_libc-uclibc = " -lrt"
61
62GTKDOC_DOCDIR = "${S}/docs/"
63
64PACKAGECONFIG ??= "xz ldconfig \
65 ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \
66 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xkbcommon', '', d)} \
67 ${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)} \
68 "
69
70PACKAGECONFIG[journal-upload] = "--enable-libcurl,--disable-libcurl,curl"
71# Sign the journal for anti-tampering
72PACKAGECONFIG[gcrypt] = "--enable-gcrypt,--disable-gcrypt,libgcrypt"
73# regardless of PACKAGECONFIG, libgcrypt is always required to expand
74# the AM_PATH_LIBGCRYPT autoconf macro
75DEPENDS += "libgcrypt"
76# Compress the journal
77PACKAGECONFIG[xz] = "--enable-xz,--disable-xz,xz"
78PACKAGECONFIG[cryptsetup] = "--enable-libcryptsetup,--disable-libcryptsetup,cryptsetup"
79PACKAGECONFIG[microhttpd] = "--enable-microhttpd,--disable-microhttpd,libmicrohttpd"
80PACKAGECONFIG[elfutils] = "--enable-elfutils,--disable-elfutils,elfutils"
81PACKAGECONFIG[resolved] = "--enable-resolved,--disable-resolved"
82PACKAGECONFIG[networkd] = "--enable-networkd,--disable-networkd"
83PACKAGECONFIG[libidn] = "--enable-libidn,--disable-libidn,libidn"
84PACKAGECONFIG[audit] = "--enable-audit,--disable-audit,audit"
85PACKAGECONFIG[manpages] = "--enable-manpages,--disable-manpages,libxslt-native xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
86PACKAGECONFIG[pam] = "--enable-pam,--disable-pam,libpam"
87# Verify keymaps on locale change
88PACKAGECONFIG[xkbcommon] = "--enable-xkbcommon,--disable-xkbcommon,libxkbcommon"
89# Update NAT firewall rules
90PACKAGECONFIG[iptc] = "--enable-libiptc,--disable-libiptc,iptables"
91PACKAGECONFIG[ldconfig] = "--enable-ldconfig,--disable-ldconfig,,"
92PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux"
93PACKAGECONFIG[valgrind] = "ac_cv_header_valgrind_memcheck_h=yes ac_cv_header_valgrind_valgrind_h=yes ,ac_cv_header_valgrind_memcheck_h=no ac_cv_header_valgrind_valgrind_h=no ,valgrind"
94
95CACHED_CONFIGUREVARS += "ac_cv_path_KILL=${base_bindir}/kill"
96CACHED_CONFIGUREVARS += "ac_cv_path_KMOD=${base_bindir}/kmod"
97CACHED_CONFIGUREVARS += "ac_cv_path_QUOTACHECK=${sbindir}/quotacheck"
98CACHED_CONFIGUREVARS += "ac_cv_path_QUOTAON=${sbindir}/quotaon"
99CACHED_CONFIGUREVARS += "ac_cv_path_SULOGIN=${base_sbindir}/sulogin"
100
101# Helper variables to clarify locations. This mirrors the logic in systemd's
102# build system.
103rootprefix ?= "${base_prefix}"
104rootlibdir ?= "${base_libdir}"
105rootlibexecdir = "${rootprefix}/lib"
106
107CACHED_CONFIGUREVARS_class-target = "\
108 ac_cv_path_MOUNT_PATH=${base_bindir}/mount \
109 ac_cv_path_UMOUNT_PATH=${base_bindir}/umount \
110 ac_cv_path_KMOD=${base_bindir}/kmod \
111 ac_cv_path_KILL=${base_bindir}/kill \
112 ac_cv_path_SULOGIN=${base_sbindir}/sulogin \
113 ac_cv_path_KEXEC=${sbindir}/kexec \
114 ac_cv_path_QUOTACHECK=${sbindir}/quotacheck \
115 ac_cv_path_QUOTAON=${sbindir}/quotaon \
116 "
117
118EXTRA_OECONF = " --with-rootprefix=${rootprefix} \
119 --with-rootlibdir=${rootlibdir} \
120 --with-roothomedir=${ROOT_HOME} \
121 --disable-coredump \
122 --disable-introspection \
123 --disable-kdbus \
124 --enable-split-usr \
125 --without-python \
126 --with-sysvrcnd-path=${sysconfdir} \
127 --with-firmware-path=/lib/firmware \
128 "
129# uclibc does not have NSS
130EXTRA_OECONF_append_libc-uclibc = " --disable-myhostname "
131
132do_configure_prepend() {
133 export NM="${HOST_PREFIX}gcc-nm"
134 export AR="${HOST_PREFIX}gcc-ar"
135 export RANLIB="${HOST_PREFIX}gcc-ranlib"
136 export KMOD="${base_bindir}/kmod"
137 if [ -d ${S}/units.pre_sed ] ; then
138 cp -r ${S}/units.pre_sed ${S}/units
139 else
140 cp -r ${S}/units ${S}/units.pre_sed
141 fi
142 sed -i '/ln --relative --help/d' ${S}/configure.ac
143 sed -i -e 's:\$(LN_S) --relative -f:lnr:g' ${S}/Makefile.am
144 sed -i -e 's:\$(LN_S) --relative:lnr:g' ${S}/Makefile.am
145}
146
147do_install() {
148 autotools_do_install
149 install -d ${D}/${base_sbindir}
150 # Provided by a separate recipe
151 rm ${D}${systemd_unitdir}/system/serial-getty* -f
152
153 # Provide support for initramfs
154 [ ! -e ${D}/init ] && ln -s ${rootlibexecdir}/systemd/systemd ${D}/init
155 [ ! -e ${D}/${base_sbindir}/udevd ] && ln -s ${rootlibexecdir}/systemd/systemd-udevd ${D}/${base_sbindir}/udevd
156
157 # Create machine-id
158 # 20:12 < mezcalero> koen: you have three options: a) run systemd-machine-id-setup at install time, b) have / read-only and an empty file there (for stateless) and c) boot with / writable
159 touch ${D}${sysconfdir}/machine-id
160
161
162 install -d ${D}${sysconfdir}/udev/rules.d/
163 install -d ${D}${sysconfdir}/tmpfiles.d
164 install -m 0644 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/
165
166 install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
167
168 if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then
169 install -d ${D}${sysconfdir}/init.d
170 install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/systemd-udevd
171 sed -i s%@UDEVD@%${rootlibexecdir}/systemd/systemd-udevd% ${D}${sysconfdir}/init.d/systemd-udevd
172 fi
173
174 chown root:systemd-journal ${D}/${localstatedir}/log/journal
175
176 # Delete journal README, as log can be symlinked inside volatile.
177 rm -f ${D}/${localstatedir}/log/README
178
179 # Create symlinks for systemd-update-utmp-runlevel.service
180 install -d ${D}${systemd_unitdir}/system/graphical.target.wants
181 install -d ${D}${systemd_unitdir}/system/multi-user.target.wants
182 install -d ${D}${systemd_unitdir}/system/poweroff.target.wants
183 install -d ${D}${systemd_unitdir}/system/reboot.target.wants
184 install -d ${D}${systemd_unitdir}/system/rescue.target.wants
185 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/graphical.target.wants/systemd-update-utmp-runlevel.service
186 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/multi-user.target.wants/systemd-update-utmp-runlevel.service
187 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/poweroff.target.wants/systemd-update-utmp-runlevel.service
188 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/reboot.target.wants/systemd-update-utmp-runlevel.service
189 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/rescue.target.wants/systemd-update-utmp-runlevel.service
190
191 # Enable journal to forward message to syslog daemon
192 sed -i -e 's/.*ForwardToSyslog.*/ForwardToSyslog=yes/' ${D}${sysconfdir}/systemd/journald.conf
193 # this file is needed to exist if networkd is disabled but timesyncd is still in use since timesyncd checks it
194 # for existence else it fails
195 if [ -s ${D}${libdir}/tmpfiles.d/systemd.conf ]; then
196 ${@bb.utils.contains('PACKAGECONFIG', 'networkd', ':', 'sed -i -e "\$ad /run/systemd/netif/links 0755 root root -" ${D}${libdir}/tmpfiles.d/systemd.conf', d)}
197 fi
198}
199
200do_install_ptest () {
201 install -d ${D}${PTEST_PATH}/test
202 cp -rf ${S}/test/* ${D}${PTEST_PATH}/test
203 install -m 0755 ${B}/test-udev ${D}${PTEST_PATH}/
204 install -d ${D}${PTEST_PATH}/build-aux
205 cp ${S}/build-aux/test-driver ${D}${PTEST_PATH}/build-aux/
206 cp -rf ${B}/rules ${D}${PTEST_PATH}/
207 # This directory needs to be there for udev-test.pl to work.
208 install -d ${D}${libdir}/udev/rules.d
209 cp ${B}/Makefile ${D}${PTEST_PATH}/
210 cp ${S}/test/sys.tar.xz ${D}${PTEST_PATH}/test
211 sed -i 's/"tree"/"ls"/' ${D}${PTEST_PATH}/test/udev-test.pl
212 sed -i 's#${S}#${PTEST_PATH}#g' ${D}${PTEST_PATH}/Makefile
213 sed -i 's#${B}#${PTEST_PATH}#g' ${D}${PTEST_PATH}/Makefile
214}
215
216python populate_packages_prepend (){
217 systemdlibdir = d.getVar("rootlibdir", True)
218 do_split_packages(d, systemdlibdir, '^lib(.*)\.so\.*', 'lib%s', 'Systemd %s library', extra_depends='', allow_links=True)
219}
220PACKAGES_DYNAMIC += "^lib(udev|systemd).*"
221
222PACKAGES =+ "${PN}-gui ${PN}-vconsole-setup ${PN}-initramfs ${PN}-analyze ${PN}-kernel-install \
223 ${PN}-rpm-macros ${PN}-binfmt ${PN}-pam ${PN}-zsh libgudev"
224
225SYSTEMD_PACKAGES = "${PN}-binfmt"
226SYSTEMD_SERVICE_${PN}-binfmt = "systemd-binfmt.service"
227
228USERADD_PACKAGES = "${PN}"
229USERADD_PARAM_${PN} += "--system systemd-journal-gateway; --system systemd-timesync"
230GROUPADD_PARAM_${PN} = "-r lock; -r systemd-journal"
231
232FILES_${PN}-analyze = "${bindir}/systemd-analyze"
233
234FILES_${PN}-initramfs = "/init"
235RDEPENDS_${PN}-initramfs = "${PN}"
236
237FILES_libgudev = "${libdir}/libgudev*${SOLIBS}"
238
239RDEPENDS_${PN}-ptest += "perl python bash"
240FILES_${PN}-ptest += "${libdir}/udev/rules.d"
241
242FILES_${PN}-dbg += "${libdir}/systemd/ptest/.debug"
243
244FILES_${PN}-gui = "${bindir}/systemadm"
245
246FILES_${PN}-vconsole-setup = "${rootlibexecdir}/systemd/systemd-vconsole-setup \
247 ${systemd_unitdir}/system/systemd-vconsole-setup.service \
248 ${systemd_unitdir}/system/sysinit.target.wants/systemd-vconsole-setup.service"
249
250RDEPENDS_${PN}-kernel-install += "bash"
251FILES_${PN}-kernel-install = "${bindir}/kernel-install \
252 ${sysconfdir}/kernel/ \
253 ${exec_prefix}/lib/kernel \
254 "
255FILES_${PN}-rpm-macros = "${exec_prefix}/lib/rpm \
256 "
257
258FILES_${PN}-zsh = "${datadir}/zsh/site-functions"
259
260FILES_${PN}-binfmt = "${sysconfdir}/binfmt.d/ \
261 ${exec_prefix}/lib/binfmt.d \
262 ${rootlibexecdir}/systemd/systemd-binfmt \
263 ${systemd_unitdir}/system/proc-sys-fs-binfmt_misc.* \
264 ${systemd_unitdir}/system/systemd-binfmt.service"
265RRECOMMENDS_${PN}-binfmt = "kernel-module-binfmt-misc"
266
267RRECOMMENDS_${PN}-vconsole-setup = "kbd kbd-consolefonts kbd-keymaps"
268
269CONFFILES_${PN} = "${sysconfdir}/systemd/journald.conf \
270 ${sysconfdir}/systemd/logind.conf \
271 ${sysconfdir}/systemd/system.conf \
272 ${sysconfdir}/systemd/user.conf"
273
274FILES_${PN} = " ${base_bindir}/* \
275 ${datadir}/bash-completion \
276 ${datadir}/dbus-1/services \
277 ${datadir}/dbus-1/system-services \
278 ${datadir}/polkit-1 \
279 ${datadir}/${BPN} \
280 ${datadir}/factory \
281 ${sysconfdir}/bash_completion.d/ \
282 ${sysconfdir}/dbus-1/ \
283 ${sysconfdir}/machine-id \
284 ${sysconfdir}/modules-load.d/ \
285 ${sysconfdir}/pam.d/ \
286 ${sysconfdir}/sysctl.d/ \
287 ${sysconfdir}/systemd/ \
288 ${sysconfdir}/tmpfiles.d/ \
289 ${sysconfdir}/xdg/ \
290 ${sysconfdir}/init.d/README \
291 ${rootlibexecdir}/systemd/* \
292 ${systemd_unitdir}/* \
293 ${base_libdir}/security/*.so \
294 ${libdir}/libnss_* \
295 /cgroup \
296 ${bindir}/systemd* \
297 ${bindir}/busctl \
298 ${bindir}/localectl \
299 ${bindir}/hostnamectl \
300 ${bindir}/timedatectl \
301 ${bindir}/bootctl \
302 ${bindir}/kernel-install \
303 ${exec_prefix}/lib/tmpfiles.d/*.conf \
304 ${exec_prefix}/lib/systemd \
305 ${exec_prefix}/lib/modules-load.d \
306 ${exec_prefix}/lib/sysctl.d \
307 ${exec_prefix}/lib/sysusers.d \
308 ${localstatedir} \
309 ${nonarch_base_libdir}/udev/rules.d/70-uaccess.rules \
310 ${nonarch_base_libdir}/udev/rules.d/71-seat.rules \
311 ${nonarch_base_libdir}/udev/rules.d/73-seat-late.rules \
312 ${nonarch_base_libdir}/udev/rules.d/99-systemd.rules \
313 "
314
315FILES_${PN}-dbg += "${rootlibdir}/.debug ${systemd_unitdir}/.debug ${systemd_unitdir}/*/.debug ${base_libdir}/security/.debug/"
316FILES_${PN}-dev += "${base_libdir}/security/*.la ${datadir}/dbus-1/interfaces/ ${sysconfdir}/rpm/macros.systemd"
317
318RDEPENDS_${PN} += "kmod dbus util-linux-mount udev (= ${EXTENDPKGV})"
319RDEPENDS_${PN} += "volatile-binds"
320
321RRECOMMENDS_${PN} += "systemd-serialgetty systemd-vconsole-setup \
322 systemd-compat-units udev-hwdb \
323 util-linux-agetty util-linux-fsck e2fsprogs-e2fsck \
324 kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 \
325 os-release \
326"
327
328PACKAGES =+ "udev-dbg udev udev-hwdb"
329
330FILES_udev-dbg += "${nonarch_base_libdir}/udev/.debug"
331
332RPROVIDES_udev = "hotplug"
333
334RDEPENDS_udev-hwdb += "udev"
335
336FILES_udev += "${base_sbindir}/udevd \
337 ${rootlibexecdir}/systemd/systemd-udevd \
338 ${rootlibexecdir}/udev/accelerometer \
339 ${rootlibexecdir}/udev/ata_id \
340 ${rootlibexecdir}/udev/cdrom_id \
341 ${rootlibexecdir}/udev/collect \
342 ${rootlibexecdir}/udev/findkeyboards \
343 ${rootlibexecdir}/udev/keyboard-force-release.sh \
344 ${rootlibexecdir}/udev/keymap \
345 ${rootlibexecdir}/udev/mtd_probe \
346 ${rootlibexecdir}/udev/scsi_id \
347 ${rootlibexecdir}/udev/v4l_id \
348 ${rootlibexecdir}/udev/keymaps \
349 ${rootlibexecdir}/udev/rules.d/*.rules \
350 ${sysconfdir}/udev \
351 ${sysconfdir}/init.d/systemd-udevd \
352 ${systemd_unitdir}/system/*udev* \
353 ${systemd_unitdir}/system/*.wants/*udev* \
354 ${base_bindir}/udevadm \
355 ${datadir}/bash-completion/completions/udevadm \
356 "
357
358FILES_udev-hwdb = "${rootlibexecdir}/udev/hwdb.d"
359
360INITSCRIPT_PACKAGES = "udev"
361INITSCRIPT_NAME_udev = "systemd-udevd"
362INITSCRIPT_PARAMS_udev = "start 03 S ."
363
364python __anonymous() {
365 if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
366 d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
367}
368
369# TODO:
370# u-a for runlevel and telinit
371
372ALTERNATIVE_${PN} = "init halt reboot shutdown poweroff runlevel"
373
374ALTERNATIVE_TARGET[init] = "${rootlibexecdir}/systemd/systemd"
375ALTERNATIVE_LINK_NAME[init] = "${base_sbindir}/init"
376ALTERNATIVE_PRIORITY[init] ?= "300"
377
378ALTERNATIVE_TARGET[halt] = "${base_bindir}/systemctl"
379ALTERNATIVE_LINK_NAME[halt] = "${base_sbindir}/halt"
380ALTERNATIVE_PRIORITY[halt] ?= "300"
381
382ALTERNATIVE_TARGET[reboot] = "${base_bindir}/systemctl"
383ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot"
384ALTERNATIVE_PRIORITY[reboot] ?= "300"
385
386ALTERNATIVE_TARGET[shutdown] = "${base_bindir}/systemctl"
387ALTERNATIVE_LINK_NAME[shutdown] = "${base_sbindir}/shutdown"
388ALTERNATIVE_PRIORITY[shutdown] ?= "300"
389
390ALTERNATIVE_TARGET[poweroff] = "${base_bindir}/systemctl"
391ALTERNATIVE_LINK_NAME[poweroff] = "${base_sbindir}/poweroff"
392ALTERNATIVE_PRIORITY[poweroff] ?= "300"
393
394ALTERNATIVE_TARGET[runlevel] = "${base_bindir}/systemctl"
395ALTERNATIVE_LINK_NAME[runlevel] = "${base_sbindir}/runlevel"
396ALTERNATIVE_PRIORITY[runlevel] ?= "300"
397
398pkg_postinst_udev-hwdb () {
399 if test -n "$D"; then
400 ${@qemu_run_binary(d, '$D', '${base_bindir}/udevadm')} hwdb --update \
401 --root $D
402 else
403 udevadm hwdb --update
404 fi
405}
406
407pkg_prerm_udev-hwdb () {
408 if test -n "$D"; then
409 exit 1
410 fi
411
412 rm -f ${sysconfdir}/udev/hwdb.bin
413}
414
415# As this recipe builds udev, respect systemd being in DISTRO_FEATURES so
416# that we don't build both udev and systemd in world builds.
417python () {
418 if not bb.utils.contains ('DISTRO_FEATURES', 'systemd', True, False, d):
419 raise bb.parse.SkipPackage("'systemd' not in DISTRO_FEATURES")
420}