summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/systemd/systemd_249.3.bb
diff options
context:
space:
mode:
authorAlexander Kanavin <alex@linutronix.de>2021-09-08 20:01:19 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-10-11 18:41:37 +0100
commitce636119aaede58b3b0b5fdf1f87dff7b42a0b7a (patch)
tree1ab4119314a9d6f6bf8c04f2ef4e32c372d5f990 /meta/recipes-core/systemd/systemd_249.3.bb
parent9ccf0f47a900c5f1569d7f7d2b720cd875827d4d (diff)
downloadpoky-ce636119aaede58b3b0b5fdf1f87dff7b42a0b7a.tar.gz
systemd: update 249.3 -> 249.4
(From OE-Core rev: 14c6e5a4b72d0e4665279158a0740dd1dc21f72f) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/systemd/systemd_249.3.bb')
-rw-r--r--meta/recipes-core/systemd/systemd_249.3.bb785
1 files changed, 0 insertions, 785 deletions
diff --git a/meta/recipes-core/systemd/systemd_249.3.bb b/meta/recipes-core/systemd/systemd_249.3.bb
deleted file mode 100644
index f8c85dabf0..0000000000
--- a/meta/recipes-core/systemd/systemd_249.3.bb
+++ /dev/null
@@ -1,785 +0,0 @@
1require systemd.inc
2
3PROVIDES = "udev"
4
5PE = "1"
6
7DEPENDS = "intltool-native gperf-native libcap util-linux python3-jinja2-native"
8
9SECTION = "base/shell"
10
11inherit useradd pkgconfig meson perlnative update-rc.d update-alternatives qemu systemd gettext bash-completion manpages features_check
12
13# As this recipe builds udev, respect systemd being in DISTRO_FEATURES so
14# that we don't build both udev and systemd in world builds.
15REQUIRED_DISTRO_FEATURES = "systemd"
16
17SRC_URI += "file://touchscreen.rules \
18 file://00-create-volatile.conf \
19 ${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', 'file://org.freedesktop.hostname1_no_polkit.conf', '', d)} \
20 ${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', 'file://00-hostnamed-network-user.conf', '', d)} \
21 file://init \
22 file://99-default.preset \
23 file://systemd-pager.sh \
24 file://0001-binfmt-Don-t-install-dependency-links-at-install-tim.patch \
25 file://0003-implment-systemd-sysv-install-for-OE.patch \
26 file://0001-systemd.pc.in-use-ROOTPREFIX-without-suffixed-slash.patch \
27 file://0001-test-parse-argument-Include-signal.h.patch \
28 "
29
30# patches needed by musl
31SRC_URI:append:libc-musl = " ${SRC_URI_MUSL}"
32SRC_URI_MUSL = "\
33 file://0002-don-t-use-glibc-specific-qsort_r.patch \
34 file://0003-missing_type.h-add-__compare_fn_t-and-comparison_fn_.patch \
35 file://0004-add-fallback-parse_printf_format-implementation.patch \
36 file://0005-src-basic-missing.h-check-for-missing-strndupa.patch \
37 file://0006-Include-netinet-if_ether.h.patch \
38 file://0007-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch \
39 file://0008-add-missing-FTW_-macros-for-musl.patch \
40 file://0009-fix-missing-of-__register_atfork-for-non-glibc-build.patch \
41 file://0010-Use-uintmax_t-for-handling-rlim_t.patch \
42 file://0011-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch \
43 file://0012-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch \
44 file://0013-Define-glibc-compatible-basename-for-non-glibc-syste.patch \
45 file://0014-Do-not-disable-buffering-when-writing-to-oom_score_a.patch \
46 file://0015-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch \
47 file://0016-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch \
48 file://0017-missing_type.h-add-__compar_d_fn_t-definition.patch \
49 file://0018-avoid-redefinition-of-prctl_mm_map-structure.patch \
50 file://0019-Handle-missing-LOCK_EX.patch \
51 file://0020-Fix-incompatible-pointer-type-struct-sockaddr_un.patch \
52 file://0021-test-json.c-define-M_PIl.patch \
53 file://0022-do-not-disable-buffer-in-writing-files.patch \
54 file://0025-Handle-__cpu_mask-usage.patch \
55 file://0026-Handle-missing-gshadow.patch \
56 file://0028-missing_syscall.h-Define-MIPS-ABI-defines-for-musl.patch \
57 "
58
59PAM_PLUGINS = " \
60 pam-plugin-unix \
61 pam-plugin-loginuid \
62 pam-plugin-keyinit \
63"
64
65PACKAGECONFIG ??= " \
66 ${@bb.utils.filter('DISTRO_FEATURES', 'acl audit efi ldconfig pam selinux smack usrmerge polkit seccomp', d)} \
67 ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'rfkill', '', d)} \
68 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xkbcommon', '', d)} \
69 backlight \
70 binfmt \
71 gshadow \
72 hibernate \
73 hostnamed \
74 idn \
75 ima \
76 kmod \
77 localed \
78 logind \
79 machined \
80 myhostname \
81 networkd \
82 nss \
83 nss-mymachines \
84 nss-resolve \
85 quotacheck \
86 randomseed \
87 resolved \
88 set-time-epoch \
89 sysusers \
90 sysvinit \
91 timedated \
92 timesyncd \
93 userdb \
94 utmp \
95 vconsole \
96 wheel-group \
97 zstd \
98"
99
100PACKAGECONFIG:remove:libc-musl = " \
101 gshadow \
102 idn \
103 localed \
104 myhostname \
105 nss \
106 nss-mymachines \
107 nss-resolve \
108 sysusers \
109 userdb \
110 utmp \
111"
112
113CFLAGS:append:libc-musl = " -D__UAPI_DEF_ETHHDR=0 "
114
115# Some of the dependencies are weak-style recommends - if not available at runtime,
116# systemd won't fail but the library-related feature will be skipped with a warning.
117
118# Use the upstream systemd serial-getty@.service and rely on
119# systemd-getty-generator instead of using the OE-core specific
120# systemd-serialgetty.bb - not enabled by default.
121PACKAGECONFIG[serial-getty-generator] = ""
122
123PACKAGECONFIG[acl] = "-Dacl=true,-Dacl=false,acl"
124PACKAGECONFIG[audit] = "-Daudit=true,-Daudit=false,audit"
125PACKAGECONFIG[backlight] = "-Dbacklight=true,-Dbacklight=false"
126PACKAGECONFIG[binfmt] = "-Dbinfmt=true,-Dbinfmt=false"
127PACKAGECONFIG[bzip2] = "-Dbzip2=true,-Dbzip2=false,bzip2"
128PACKAGECONFIG[cgroupv2] = "-Ddefault-hierarchy=unified,-Ddefault-hierarchy=hybrid"
129PACKAGECONFIG[coredump] = "-Dcoredump=true,-Dcoredump=false"
130PACKAGECONFIG[cryptsetup] = "-Dlibcryptsetup=true,-Dlibcryptsetup=false,cryptsetup,,cryptsetup"
131PACKAGECONFIG[tpm2] = "-Dtpm2=true,-Dtpm2=false,tpm2-tss,tpm2-tss libtss2 libtss2-tcti-device"
132PACKAGECONFIG[dbus] = "-Ddbus=true,-Ddbus=false,dbus"
133PACKAGECONFIG[efi] = "-Defi=true,-Defi=false"
134PACKAGECONFIG[gnu-efi] = "-Dgnu-efi=true -Defi-libdir=${STAGING_LIBDIR} -Defi-includedir=${STAGING_INCDIR}/efi,-Dgnu-efi=false,gnu-efi"
135PACKAGECONFIG[elfutils] = "-Delfutils=true,-Delfutils=false,elfutils"
136PACKAGECONFIG[firstboot] = "-Dfirstboot=true,-Dfirstboot=false"
137PACKAGECONFIG[repart] = "-Drepart=true,-Drepart=false"
138PACKAGECONFIG[homed] = "-Dhomed=true,-Dhomed=false"
139# Sign the journal for anti-tampering
140PACKAGECONFIG[gcrypt] = "-Dgcrypt=true,-Dgcrypt=false,libgcrypt"
141PACKAGECONFIG[gnutls] = "-Dgnutls=true,-Dgnutls=false,gnutls"
142PACKAGECONFIG[gshadow] = "-Dgshadow=true,-Dgshadow=false"
143PACKAGECONFIG[hibernate] = "-Dhibernate=true,-Dhibernate=false"
144PACKAGECONFIG[hostnamed] = "-Dhostnamed=true,-Dhostnamed=false"
145PACKAGECONFIG[idn] = "-Didn=true,-Didn=false"
146PACKAGECONFIG[ima] = "-Dima=true,-Dima=false"
147# importd requires journal-upload/xz/zlib/bzip2/gcrypt
148PACKAGECONFIG[importd] = "-Dimportd=true,-Dimportd=false"
149# Update NAT firewall rules
150PACKAGECONFIG[iptc] = "-Dlibiptc=true,-Dlibiptc=false,iptables"
151PACKAGECONFIG[journal-upload] = "-Dlibcurl=true,-Dlibcurl=false,curl"
152PACKAGECONFIG[kmod] = "-Dkmod=true,-Dkmod=false,kmod"
153PACKAGECONFIG[ldconfig] = "-Dldconfig=true,-Dldconfig=false,,ldconfig"
154PACKAGECONFIG[libidn] = "-Dlibidn=true,-Dlibidn=false,libidn,,libidn"
155PACKAGECONFIG[libidn2] = "-Dlibidn2=true,-Dlibidn2=false,libidn2,,libidn2"
156PACKAGECONFIG[localed] = "-Dlocaled=true,-Dlocaled=false"
157PACKAGECONFIG[logind] = "-Dlogind=true,-Dlogind=false"
158PACKAGECONFIG[lz4] = "-Dlz4=true,-Dlz4=false,lz4"
159PACKAGECONFIG[machined] = "-Dmachined=true,-Dmachined=false"
160PACKAGECONFIG[manpages] = "-Dman=true,-Dman=false,libxslt-native xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
161PACKAGECONFIG[microhttpd] = "-Dmicrohttpd=true,-Dmicrohttpd=false,libmicrohttpd"
162PACKAGECONFIG[myhostname] = "-Dnss-myhostname=true,-Dnss-myhostname=false,,libnss-myhostname"
163PACKAGECONFIG[networkd] = "-Dnetworkd=true,-Dnetworkd=false"
164PACKAGECONFIG[nss] = "-Dnss-systemd=true,-Dnss-systemd=false"
165PACKAGECONFIG[nss-mymachines] = "-Dnss-mymachines=true,-Dnss-mymachines=false"
166PACKAGECONFIG[nss-resolve] = "-Dnss-resolve=true,-Dnss-resolve=false"
167PACKAGECONFIG[oomd] = "-Doomd=true,-Doomd=false"
168PACKAGECONFIG[openssl] = "-Dopenssl=true,-Dopenssl=false,openssl"
169PACKAGECONFIG[pam] = "-Dpam=true,-Dpam=false,libpam,${PAM_PLUGINS}"
170PACKAGECONFIG[pcre2] = "-Dpcre2=true,-Dpcre2=false,libpcre2"
171PACKAGECONFIG[polkit] = "-Dpolkit=true,-Dpolkit=false"
172# If polkit is disabled and networkd+hostnamed are in use, enabling this option and
173# using dbus-broker will allow networkd to be authorized to change the
174# hostname without acquiring additional privileges
175PACKAGECONFIG[polkit_hostnamed_fallback] = ",,,,dbus-broker,polkit"
176PACKAGECONFIG[portabled] = "-Dportabled=true,-Dportabled=false"
177PACKAGECONFIG[qrencode] = "-Dqrencode=true,-Dqrencode=false,qrencode,,qrencode"
178PACKAGECONFIG[quotacheck] = "-Dquotacheck=true,-Dquotacheck=false"
179PACKAGECONFIG[randomseed] = "-Drandomseed=true,-Drandomseed=false"
180PACKAGECONFIG[resolved] = "-Dresolve=true,-Dresolve=false"
181PACKAGECONFIG[rfkill] = "-Drfkill=true,-Drfkill=false"
182PACKAGECONFIG[seccomp] = "-Dseccomp=true,-Dseccomp=false,libseccomp"
183PACKAGECONFIG[selinux] = "-Dselinux=true,-Dselinux=false,libselinux,initscripts-sushell"
184PACKAGECONFIG[smack] = "-Dsmack=true,-Dsmack=false"
185PACKAGECONFIG[sysusers] = "-Dsysusers=true,-Dsysusers=false"
186PACKAGECONFIG[sysvinit] = "-Dsysvinit-path=${sysconfdir}/init.d -Dsysvrcnd-path=${sysconfdir},-Dsysvinit-path= -Dsysvrcnd-path=,,systemd-compat-units update-rc.d"
187# When enabled use reproducble build timestamp if set as time epoch,
188# or build time if not. When disabled, time epoch is unset.
189def build_epoch(d):
190 epoch = d.getVar('SOURCE_DATE_EPOCH') or "-1"
191 return '-Dtime-epoch=%d' % int(epoch)
192PACKAGECONFIG[set-time-epoch] = "${@build_epoch(d)},-Dtime-epoch=0"
193PACKAGECONFIG[timedated] = "-Dtimedated=true,-Dtimedated=false"
194PACKAGECONFIG[timesyncd] = "-Dtimesyncd=true,-Dtimesyncd=false"
195PACKAGECONFIG[usrmerge] = "-Dsplit-usr=false,-Dsplit-usr=true"
196PACKAGECONFIG[sbinmerge] = "-Dsplit-bin=false,-Dsplit-bin=true"
197PACKAGECONFIG[userdb] = "-Duserdb=true,-Duserdb=false"
198PACKAGECONFIG[utmp] = "-Dutmp=true,-Dutmp=false"
199PACKAGECONFIG[valgrind] = "-DVALGRIND=1,,valgrind"
200PACKAGECONFIG[vconsole] = "-Dvconsole=true,-Dvconsole=false,,${PN}-vconsole-setup"
201PACKAGECONFIG[wheel-group] = "-Dwheel-group=true, -Dwheel-group=false"
202PACKAGECONFIG[xdg-autostart] = "-Dxdg-autostart=true,-Dxdg-autostart=false"
203# Verify keymaps on locale change
204PACKAGECONFIG[xkbcommon] = "-Dxkbcommon=true,-Dxkbcommon=false,libxkbcommon"
205PACKAGECONFIG[xz] = "-Dxz=true,-Dxz=false,xz"
206PACKAGECONFIG[zlib] = "-Dzlib=true,-Dzlib=false,zlib"
207PACKAGECONFIG[zstd] = "-Dzstd=true,-Dzstd=false,zstd"
208
209# Helper variables to clarify locations. This mirrors the logic in systemd's
210# build system.
211rootprefix ?= "${root_prefix}"
212rootlibdir ?= "${base_libdir}"
213rootlibexecdir = "${rootprefix}/lib"
214
215# This links udev statically with systemd helper library.
216# Otherwise udev package would depend on systemd package (which has the needed shared library),
217# and always pull it into images.
218EXTRA_OEMESON += "-Dlink-udev-shared=false"
219
220EXTRA_OEMESON += "-Dnobody-user=nobody \
221 -Dnobody-group=nobody \
222 -Drootlibdir=${rootlibdir} \
223 -Drootprefix=${rootprefix} \
224 -Ddefault-locale=C \
225 -Dmode=release \
226 -Dsystem-alloc-uid-min=101 \
227 -Dsystem-uid-max=999 \
228 -Dsystem-alloc-gid-min=101 \
229 -Dsystem-gid-max=999 \
230 "
231
232# Hardcode target binary paths to avoid using paths from sysroot
233EXTRA_OEMESON += "-Dkexec-path=${sbindir}/kexec \
234 -Dkmod-path=${base_bindir}/kmod \
235 -Dmount-path=${base_bindir}/mount \
236 -Dquotacheck-path=${sbindir}/quotacheck \
237 -Dquotaon-path=${sbindir}/quotaon \
238 -Dsulogin-path=${base_sbindir}/sulogin \
239 -Dnologin-path=${base_sbindir}/nologin \
240 -Dumount-path=${base_bindir}/umount"
241
242do_install() {
243 meson_do_install
244 install -d ${D}/${base_sbindir}
245 if ${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', 'false', 'true', d)}; then
246 # Provided by a separate recipe
247 rm ${D}${systemd_system_unitdir}/serial-getty* -f
248 fi
249
250 # Provide support for initramfs
251 [ ! -e ${D}/init ] && ln -s ${rootlibexecdir}/systemd/systemd ${D}/init
252 [ ! -e ${D}/${base_sbindir}/udevd ] && ln -s ${rootlibexecdir}/systemd/systemd-udevd ${D}/${base_sbindir}/udevd
253
254 install -d ${D}${sysconfdir}/udev/rules.d/
255 install -d ${D}${sysconfdir}/tmpfiles.d
256 for rule in $(find ${WORKDIR} -maxdepth 1 -type f -name "*.rules"); do
257 install -m 0644 $rule ${D}${sysconfdir}/udev/rules.d/
258 done
259
260 install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
261
262 if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then
263 install -d ${D}${sysconfdir}/init.d
264 install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/systemd-udevd
265 sed -i s%@UDEVD@%${rootlibexecdir}/systemd/systemd-udevd% ${D}${sysconfdir}/init.d/systemd-udevd
266 install -Dm 0755 ${S}/src/systemctl/systemd-sysv-install.SKELETON ${D}${systemd_system_unitdir}d-sysv-install
267 fi
268
269 chown root:systemd-journal ${D}/${localstatedir}/log/journal
270
271 # Delete journal README, as log can be symlinked inside volatile.
272 rm -f ${D}/${localstatedir}/log/README
273
274 # journal-remote creates this at start
275 rm -rf ${D}/${localstatedir}/log/journal/remote
276
277 install -d ${D}${systemd_system_unitdir}/graphical.target.wants
278 install -d ${D}${systemd_system_unitdir}/multi-user.target.wants
279 install -d ${D}${systemd_system_unitdir}/poweroff.target.wants
280 install -d ${D}${systemd_system_unitdir}/reboot.target.wants
281 install -d ${D}${systemd_system_unitdir}/rescue.target.wants
282
283 # Create symlinks for systemd-update-utmp-runlevel.service
284 if ${@bb.utils.contains('PACKAGECONFIG', 'utmp', 'true', 'false', d)}; then
285 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_system_unitdir}/graphical.target.wants/systemd-update-utmp-runlevel.service
286 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_system_unitdir}/multi-user.target.wants/systemd-update-utmp-runlevel.service
287 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_system_unitdir}/poweroff.target.wants/systemd-update-utmp-runlevel.service
288 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_system_unitdir}/reboot.target.wants/systemd-update-utmp-runlevel.service
289 ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_system_unitdir}/rescue.target.wants/systemd-update-utmp-runlevel.service
290 fi
291
292 # this file is needed to exist if networkd is disabled but timesyncd is still in use since timesyncd checks it
293 # for existence else it fails
294 if [ -s ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf ]; then
295 ${@bb.utils.contains('PACKAGECONFIG', 'networkd', ':', 'sed -i -e "\$ad /run/systemd/netif/links 0755 root root -" ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf', d)}
296 fi
297 if ! ${@bb.utils.contains('PACKAGECONFIG', 'resolved', 'true', 'false', d)}; then
298 echo 'L! ${sysconfdir}/resolv.conf - - - - ../run/systemd/resolve/resolv.conf' >>${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
299 echo 'd /run/systemd/resolve 0755 root root -' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
300 echo 'f /run/systemd/resolve/resolv.conf 0644 root root' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
301 ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
302 else
303 sed -i -e "s%^L! /etc/resolv.conf.*$%L! /etc/resolv.conf - - - - ../run/systemd/resolve/resolv.conf%g" ${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
304 ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
305 fi
306 if ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'false', 'true', d)}; then
307 rm ${D}${exec_prefix}/lib/tmpfiles.d/x11.conf
308 rm -r ${D}${sysconfdir}/X11
309 fi
310
311 # If polkit is setup fixup permissions and ownership
312 if ${@bb.utils.contains('PACKAGECONFIG', 'polkit', 'true', 'false', d)}; then
313 if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
314 chmod 700 ${D}${datadir}/polkit-1/rules.d
315 chown polkitd:root ${D}${datadir}/polkit-1/rules.d
316 fi
317 fi
318
319 # If polkit is not available and a fallback was requested, install a drop-in that allows networkd to
320 # request hostname changes via DBUS without elevating its privileges
321 if ${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', 'true', 'false', d)}; then
322 install -d ${D}${systemd_system_unitdir}/systemd-hostnamed.service.d/
323 install -m 0644 ${WORKDIR}/00-hostnamed-network-user.conf ${D}${systemd_system_unitdir}/systemd-hostnamed.service.d/
324 install -d ${D}${datadir}/dbus-1/system.d/
325 install -m 0644 ${WORKDIR}/org.freedesktop.hostname1_no_polkit.conf ${D}${datadir}/dbus-1/system.d/
326 fi
327
328 # create link for existing udev rules
329 ln -s ${base_bindir}/udevadm ${D}${base_sbindir}/udevadm
330
331 # duplicate udevadm for postinst script
332 install -d ${D}${libexecdir}
333 ln ${D}${base_bindir}/udevadm ${D}${libexecdir}/${MLPREFIX}udevadm
334
335 # install default policy for presets
336 # https://www.freedesktop.org/wiki/Software/systemd/Preset/#howto
337 install -Dm 0644 ${WORKDIR}/99-default.preset ${D}${systemd_system_unitdir}-preset/99-default.preset
338
339 # add a profile fragment to disable systemd pager with busybox less
340 install -Dm 0644 ${WORKDIR}/systemd-pager.sh ${D}${sysconfdir}/profile.d/systemd-pager.sh
341}
342
343python populate_packages:prepend (){
344 systemdlibdir = d.getVar("rootlibdir")
345 do_split_packages(d, systemdlibdir, '^lib(.*)\.so\.*', 'lib%s', 'Systemd %s library', extra_depends='', allow_links=True)
346}
347PACKAGES_DYNAMIC += "^lib(udev|systemd|nss).*"
348
349PACKAGE_BEFORE_PN = "\
350 ${PN}-gui \
351 ${PN}-vconsole-setup \
352 ${PN}-initramfs \
353 ${PN}-analyze \
354 ${PN}-kernel-install \
355 ${PN}-rpm-macros \
356 ${PN}-binfmt \
357 ${PN}-zsh-completion \
358 ${PN}-container \
359 ${PN}-journal-gatewayd \
360 ${PN}-journal-upload \
361 ${PN}-journal-remote \
362 ${PN}-extra-utils \
363 ${PN}-udev-rules \
364 udev \
365 udev-hwdb \
366"
367
368SUMMARY:${PN}-container = "Tools for containers and VMs"
369DESCRIPTION:${PN}-container = "Systemd tools to spawn and manage containers and virtual machines."
370
371SUMMARY:${PN}-journal-gatewayd = "HTTP server for journal events"
372DESCRIPTION:${PN}-journal-gatewayd = "systemd-journal-gatewayd serves journal events over the network. Clients must connect using HTTP. The server listens on port 19531 by default."
373
374SUMMARY:${PN}-journal-upload = "Send journal messages over the network"
375DESCRIPTION:${PN}-journal-upload = "systemd-journal-upload uploads journal entries to a specified URL."
376
377SUMMARY:${PN}-journal-remote = "Receive journal messages over the network"
378DESCRIPTION:${PN}-journal-remote = "systemd-journal-remote is a command to receive serialized journal events and store them to journal files."
379
380SYSTEMD_PACKAGES = "${@bb.utils.contains('PACKAGECONFIG', 'binfmt', '${PN}-binfmt', '', d)} \
381 ${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '${PN}-journal-gatewayd', '', d)} \
382 ${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '${PN}-journal-remote', '', d)} \
383 ${@bb.utils.contains('PACKAGECONFIG', 'journal-upload', '${PN}-journal-upload', '', d)} \
384"
385SYSTEMD_SERVICE:${PN}-binfmt = "systemd-binfmt.service"
386
387USERADD_PACKAGES = "${PN} ${PN}-extra-utils \
388 ${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '${PN}-journal-gateway', '', d)} \
389 ${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '${PN}-journal-remote', '', d)} \
390 ${@bb.utils.contains('PACKAGECONFIG', 'journal-upload', '${PN}-journal-upload', '', d)} \
391"
392GROUPADD_PARAM:${PN} = "-r systemd-journal;"
393GROUPADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', '-r systemd-hostname;', '', d)}"
394USERADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'coredump', '--system -d / -M --shell /sbin/nologin systemd-coredump;', '', d)}"
395USERADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'networkd', '--system -d / -M --shell /sbin/nologin systemd-network;', '', d)}"
396USERADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'polkit', '--system --no-create-home --user-group --home-dir ${sysconfdir}/polkit-1 polkitd;', '', d)}"
397USERADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'resolved', '--system -d / -M --shell /sbin/nologin systemd-resolve;', '', d)}"
398USERADD_PARAM:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'timesyncd', '--system -d / -M --shell /sbin/nologin systemd-timesync;', '', d)}"
399USERADD_PARAM:${PN}-extra-utils = "--system -d / -M --shell /sbin/nologin systemd-bus-proxy"
400USERADD_PARAM:${PN}-journal-gateway = "--system -d / -M --shell /sbin/nologin systemd-journal-gateway"
401USERADD_PARAM:${PN}-journal-remote = "--system -d / -M --shell /sbin/nologin systemd-journal-remote"
402USERADD_PARAM:${PN}-journal-upload = "--system -d / -M --shell /sbin/nologin systemd-journal-upload"
403
404FILES:${PN}-analyze = "${bindir}/systemd-analyze"
405
406FILES:${PN}-initramfs = "/init"
407RDEPENDS:${PN}-initramfs = "${PN}"
408
409FILES:${PN}-gui = "${bindir}/systemadm"
410
411FILES:${PN}-vconsole-setup = "${rootlibexecdir}/systemd/systemd-vconsole-setup \
412 ${systemd_system_unitdir}/systemd-vconsole-setup.service \
413 ${systemd_system_unitdir}/sysinit.target.wants/systemd-vconsole-setup.service"
414
415RDEPENDS:${PN}-kernel-install += "bash"
416FILES:${PN}-kernel-install = "${bindir}/kernel-install \
417 ${sysconfdir}/kernel/ \
418 ${exec_prefix}/lib/kernel \
419 "
420FILES:${PN}-rpm-macros = "${exec_prefix}/lib/rpm \
421 "
422
423FILES:${PN}-zsh-completion = "${datadir}/zsh/site-functions"
424
425FILES:${PN}-binfmt = "${sysconfdir}/binfmt.d/ \
426 ${exec_prefix}/lib/binfmt.d \
427 ${rootlibexecdir}/systemd/systemd-binfmt \
428 ${systemd_system_unitdir}/proc-sys-fs-binfmt_misc.* \
429 ${systemd_system_unitdir}/systemd-binfmt.service"
430RRECOMMENDS:${PN}-binfmt = "kernel-module-binfmt-misc"
431
432RRECOMMENDS:${PN}-vconsole-setup = "kbd kbd-consolefonts kbd-keymaps"
433
434
435FILES:${PN}-journal-gatewayd = "${rootlibexecdir}/systemd/systemd-journal-gatewayd \
436 ${systemd_system_unitdir}/systemd-journal-gatewayd.service \
437 ${systemd_system_unitdir}/systemd-journal-gatewayd.socket \
438 ${systemd_system_unitdir}/sockets.target.wants/systemd-journal-gatewayd.socket \
439 ${datadir}/systemd/gatewayd/browse.html \
440 "
441SYSTEMD_SERVICE:${PN}-journal-gatewayd = "systemd-journal-gatewayd.socket"
442
443FILES:${PN}-journal-upload = "${rootlibexecdir}/systemd/systemd-journal-upload \
444 ${systemd_system_unitdir}/systemd-journal-upload.service \
445 ${sysconfdir}/systemd/journal-upload.conf \
446 "
447SYSTEMD_SERVICE:${PN}-journal-upload = "systemd-journal-upload.service"
448
449FILES:${PN}-journal-remote = "${rootlibexecdir}/systemd/systemd-journal-remote \
450 ${sysconfdir}/systemd/journal-remote.conf \
451 ${systemd_system_unitdir}/systemd-journal-remote.service \
452 ${systemd_system_unitdir}/systemd-journal-remote.socket \
453 "
454SYSTEMD_SERVICE:${PN}-journal-remote = "systemd-journal-remote.socket"
455
456
457FILES:${PN}-container = "${sysconfdir}/dbus-1/system.d/org.freedesktop.import1.conf \
458 ${sysconfdir}/dbus-1/system.d/org.freedesktop.machine1.conf \
459 ${sysconfdir}/systemd/system/multi-user.target.wants/machines.target \
460 ${base_bindir}/machinectl \
461 ${bindir}/systemd-nspawn \
462 ${nonarch_libdir}/systemd/import-pubring.gpg \
463 ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.import1.busname \
464 ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.machine1.busname \
465 ${systemd_system_unitdir}/local-fs.target.wants/var-lib-machines.mount \
466 ${systemd_system_unitdir}/machines.target.wants/var-lib-machines.mount \
467 ${systemd_system_unitdir}/remote-fs.target.wants/var-lib-machines.mount \
468 ${systemd_system_unitdir}/machine.slice \
469 ${systemd_system_unitdir}/machines.target \
470 ${systemd_system_unitdir}/org.freedesktop.import1.busname \
471 ${systemd_system_unitdir}/org.freedesktop.machine1.busname \
472 ${systemd_system_unitdir}/systemd-importd.service \
473 ${systemd_system_unitdir}/systemd-machined.service \
474 ${systemd_system_unitdir}/dbus-org.freedesktop.machine1.service \
475 ${systemd_system_unitdir}/var-lib-machines.mount \
476 ${rootlibexecdir}/systemd/systemd-import \
477 ${rootlibexecdir}/systemd/systemd-importd \
478 ${rootlibexecdir}/systemd/systemd-machined \
479 ${rootlibexecdir}/systemd/systemd-pull \
480 ${exec_prefix}/lib/tmpfiles.d/systemd-nspawn.conf \
481 ${exec_prefix}/lib/tmpfiles.d/README \
482 ${systemd_system_unitdir}/systemd-nspawn@.service \
483 ${libdir}/libnss_mymachines.so.2 \
484 ${datadir}/dbus-1/system-services/org.freedesktop.import1.service \
485 ${datadir}/dbus-1/system-services/org.freedesktop.machine1.service \
486 ${datadir}/dbus-1/system.d/org.freedesktop.import1.conf \
487 ${datadir}/dbus-1/system.d/org.freedesktop.machine1.conf \
488 ${datadir}/polkit-1/actions/org.freedesktop.import1.policy \
489 ${datadir}/polkit-1/actions/org.freedesktop.machine1.policy \
490 "
491
492# "machinectl import-tar" uses "tar --numeric-owner", not supported by busybox.
493RRECOMMENDS:${PN}-container += "\
494 ${PN}-journal-gatewayd \
495 ${PN}-journal-remote \
496 ${PN}-journal-upload \
497 kernel-module-dm-mod \
498 kernel-module-loop \
499 kernel-module-tun \
500 tar \
501 "
502
503FILES:${PN}-extra-utils = "\
504 ${base_bindir}/systemd-escape \
505 ${base_bindir}/systemd-inhibit \
506 ${bindir}/systemd-detect-virt \
507 ${bindir}/systemd-dissect \
508 ${bindir}/systemd-path \
509 ${bindir}/systemd-run \
510 ${bindir}/systemd-cat \
511 ${bindir}/systemd-delta \
512 ${bindir}/systemd-cgls \
513 ${bindir}/systemd-cgtop \
514 ${bindir}/systemd-stdio-bridge \
515 ${bindir}/systemd-sysext \
516 ${base_bindir}/systemd-ask-password \
517 ${base_bindir}/systemd-tty-ask-password-agent \
518 ${systemd_system_unitdir}/systemd-ask-password-console.path \
519 ${systemd_system_unitdir}/systemd-ask-password-console.service \
520 ${systemd_system_unitdir}/systemd-ask-password-wall.path \
521 ${systemd_system_unitdir}/systemd-ask-password-wall.service \
522 ${systemd_system_unitdir}/sysinit.target.wants/systemd-ask-password-console.path \
523 ${systemd_system_unitdir}/sysinit.target.wants/systemd-ask-password-wall.path \
524 ${systemd_system_unitdir}/multi-user.target.wants/systemd-ask-password-wall.path \
525 ${rootlibexecdir}/systemd/systemd-resolve-host \
526 ${rootlibexecdir}/systemd/systemd-ac-power \
527 ${rootlibexecdir}/systemd/systemd-activate \
528 ${rootlibexecdir}/systemd/systemd-bus-proxyd \
529 ${systemd_system_unitdir}/systemd-bus-proxyd.service \
530 ${systemd_system_unitdir}/systemd-bus-proxyd.socket \
531 ${rootlibexecdir}/systemd/systemd-socket-proxyd \
532 ${rootlibexecdir}/systemd/systemd-reply-password \
533 ${rootlibexecdir}/systemd/systemd-sleep \
534 ${rootlibexecdir}/systemd/system-sleep \
535 ${systemd_system_unitdir}/systemd-hibernate.service \
536 ${systemd_system_unitdir}/systemd-hybrid-sleep.service \
537 ${systemd_system_unitdir}/systemd-suspend.service \
538 ${systemd_system_unitdir}/sleep.target \
539 ${rootlibexecdir}/systemd/systemd-initctl \
540 ${systemd_system_unitdir}/systemd-initctl.service \
541 ${systemd_system_unitdir}/systemd-initctl.socket \
542 ${systemd_system_unitdir}/sockets.target.wants/systemd-initctl.socket \
543 ${rootlibexecdir}/systemd/system-generators/systemd-gpt-auto-generator \
544 ${rootlibexecdir}/systemd/systemd-cgroups-agent \
545"
546
547FILES:${PN}-udev-rules = "\
548 ${rootlibexecdir}/udev/rules.d/70-uaccess.rules \
549 ${rootlibexecdir}/udev/rules.d/71-seat.rules \
550 ${rootlibexecdir}/udev/rules.d/73-seat-late.rules \
551 ${rootlibexecdir}/udev/rules.d/99-systemd.rules \
552"
553
554CONFFILES:${PN} = "${sysconfdir}/systemd/coredump.conf \
555 ${sysconfdir}/systemd/journald.conf \
556 ${sysconfdir}/systemd/logind.conf \
557 ${sysconfdir}/systemd/networkd.conf \
558 ${sysconfdir}/systemd/pstore.conf \
559 ${sysconfdir}/systemd/resolved.conf \
560 ${sysconfdir}/systemd/sleep.conf \
561 ${sysconfdir}/systemd/system.conf \
562 ${sysconfdir}/systemd/timesyncd.conf \
563 ${sysconfdir}/systemd/user.conf \
564"
565
566FILES:${PN} = " ${base_bindir}/* \
567 ${base_sbindir}/shutdown \
568 ${base_sbindir}/halt \
569 ${base_sbindir}/poweroff \
570 ${base_sbindir}/runlevel \
571 ${base_sbindir}/telinit \
572 ${base_sbindir}/resolvconf \
573 ${base_sbindir}/reboot \
574 ${base_sbindir}/init \
575 ${datadir}/dbus-1/services \
576 ${datadir}/dbus-1/system-services \
577 ${datadir}/polkit-1 \
578 ${datadir}/${BPN} \
579 ${datadir}/factory \
580 ${sysconfdir}/dbus-1/ \
581 ${sysconfdir}/modules-load.d/ \
582 ${sysconfdir}/pam.d/ \
583 ${sysconfdir}/profile.d/ \
584 ${sysconfdir}/sysctl.d/ \
585 ${sysconfdir}/systemd/ \
586 ${sysconfdir}/tmpfiles.d/ \
587 ${sysconfdir}/xdg/ \
588 ${sysconfdir}/init.d/README \
589 ${sysconfdir}/resolv-conf.systemd \
590 ${sysconfdir}/X11/xinit/xinitrc.d/* \
591 ${rootlibexecdir}/systemd/* \
592 ${libdir}/pam.d \
593 ${nonarch_libdir}/pam.d \
594 ${systemd_unitdir}/* \
595 ${base_libdir}/security/*.so \
596 /cgroup \
597 ${bindir}/systemd* \
598 ${bindir}/busctl \
599 ${bindir}/coredumpctl \
600 ${bindir}/localectl \
601 ${bindir}/hostnamectl \
602 ${bindir}/resolvectl \
603 ${bindir}/timedatectl \
604 ${bindir}/bootctl \
605 ${bindir}/oomctl \
606 ${exec_prefix}/lib/tmpfiles.d/*.conf \
607 ${exec_prefix}/lib/systemd \
608 ${exec_prefix}/lib/modules-load.d \
609 ${exec_prefix}/lib/sysctl.d \
610 ${exec_prefix}/lib/sysusers.d \
611 ${exec_prefix}/lib/environment.d \
612 ${localstatedir} \
613 ${rootlibexecdir}/modprobe.d/systemd.conf \
614 ${rootlibexecdir}/modprobe.d/README \
615 ${datadir}/dbus-1/system.d/org.freedesktop.timedate1.conf \
616 ${datadir}/dbus-1/system.d/org.freedesktop.locale1.conf \
617 ${datadir}/dbus-1/system.d/org.freedesktop.network1.conf \
618 ${datadir}/dbus-1/system.d/org.freedesktop.resolve1.conf \
619 ${datadir}/dbus-1/system.d/org.freedesktop.systemd1.conf \
620 ${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', '${datadir}/dbus-1/system.d/org.freedesktop.hostname1_no_polkit.conf', '', d)} \
621 ${datadir}/dbus-1/system.d/org.freedesktop.hostname1.conf \
622 ${datadir}/dbus-1/system.d/org.freedesktop.login1.conf \
623 ${datadir}/dbus-1/system.d/org.freedesktop.timesync1.conf \
624 ${datadir}/dbus-1/system.d/org.freedesktop.portable1.conf \
625 ${datadir}/dbus-1/system.d/org.freedesktop.oom1.conf \
626 ${datadir}/dbus-1/system.d/org.freedesktop.home1.conf \
627 "
628
629FILES:${PN}-dev += "${base_libdir}/security/*.la ${datadir}/dbus-1/interfaces/ ${sysconfdir}/rpm/macros.systemd"
630
631RDEPENDS:${PN} += "kmod dbus util-linux-mount util-linux-umount udev (= ${EXTENDPKGV}) systemd-udev-rules util-linux-agetty util-linux-fsck"
632RDEPENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', '', 'systemd-serialgetty', d)}"
633RDEPENDS:${PN} += "volatile-binds"
634
635RRECOMMENDS:${PN} += "systemd-extra-utils \
636 udev-hwdb \
637 e2fsprogs-e2fsck \
638 kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 kernel-module-sch-fq-codel \
639 os-release \
640 systemd-conf \
641"
642
643INSANE_SKIP:${PN} += "dev-so libdir"
644INSANE_SKIP:${PN}-dbg += "libdir"
645INSANE_SKIP:${PN}-doc += " libdir"
646
647RPROVIDES:udev = "hotplug"
648
649RDEPENDS:udev-hwdb += "udev"
650
651FILES:udev += "${base_sbindir}/udevd \
652 ${rootlibexecdir}/systemd/network/99-default.link \
653 ${rootlibexecdir}/systemd/systemd-udevd \
654 ${rootlibexecdir}/udev/accelerometer \
655 ${rootlibexecdir}/udev/ata_id \
656 ${rootlibexecdir}/udev/cdrom_id \
657 ${rootlibexecdir}/udev/collect \
658 ${rootlibexecdir}/udev/dmi_memory_id \
659 ${rootlibexecdir}/udev/fido_id \
660 ${rootlibexecdir}/udev/findkeyboards \
661 ${rootlibexecdir}/udev/keyboard-force-release.sh \
662 ${rootlibexecdir}/udev/keymap \
663 ${rootlibexecdir}/udev/mtd_probe \
664 ${rootlibexecdir}/udev/scsi_id \
665 ${rootlibexecdir}/udev/v4l_id \
666 ${rootlibexecdir}/udev/keymaps \
667 ${rootlibexecdir}/udev/rules.d/50-udev-default.rules \
668 ${rootlibexecdir}/udev/rules.d/60-autosuspend.rules \
669 ${rootlibexecdir}/udev/rules.d/60-autosuspend-chromiumos.rules \
670 ${rootlibexecdir}/udev/rules.d/60-block.rules \
671 ${rootlibexecdir}/udev/rules.d/60-cdrom_id.rules \
672 ${rootlibexecdir}/udev/rules.d/60-drm.rules \
673 ${rootlibexecdir}/udev/rules.d/60-evdev.rules \
674 ${rootlibexecdir}/udev/rules.d/60-fido-id.rules \
675 ${rootlibexecdir}/udev/rules.d/60-input-id.rules \
676 ${rootlibexecdir}/udev/rules.d/60-persistent-alsa.rules \
677 ${rootlibexecdir}/udev/rules.d/60-persistent-input.rules \
678 ${rootlibexecdir}/udev/rules.d/60-persistent-storage.rules \
679 ${rootlibexecdir}/udev/rules.d/60-persistent-storage-tape.rules \
680 ${rootlibexecdir}/udev/rules.d/60-persistent-v4l.rules \
681 ${rootlibexecdir}/udev/rules.d/60-sensor.rules \
682 ${rootlibexecdir}/udev/rules.d/60-serial.rules \
683 ${rootlibexecdir}/udev/rules.d/61-autosuspend-manual.rules \
684 ${rootlibexecdir}/udev/rules.d/64-btrfs.rules \
685 ${rootlibexecdir}/udev/rules.d/70-joystick.rules \
686 ${rootlibexecdir}/udev/rules.d/70-memory.rules \
687 ${rootlibexecdir}/udev/rules.d/70-mouse.rules \
688 ${rootlibexecdir}/udev/rules.d/70-power-switch.rules \
689 ${rootlibexecdir}/udev/rules.d/70-touchpad.rules \
690 ${rootlibexecdir}/udev/rules.d/75-net-description.rules \
691 ${rootlibexecdir}/udev/rules.d/75-probe_mtd.rules \
692 ${rootlibexecdir}/udev/rules.d/78-sound-card.rules \
693 ${rootlibexecdir}/udev/rules.d/80-drivers.rules \
694 ${rootlibexecdir}/udev/rules.d/80-net-setup-link.rules \
695 ${rootlibexecdir}/udev/rules.d/81-net-dhcp.rules \
696 ${rootlibexecdir}/udev/rules.d/90-vconsole.rules \
697 ${rootlibexecdir}/udev/rules.d/README \
698 ${sysconfdir}/udev \
699 ${sysconfdir}/init.d/systemd-udevd \
700 ${systemd_system_unitdir}/*udev* \
701 ${systemd_system_unitdir}/*.wants/*udev* \
702 ${base_bindir}/systemd-hwdb \
703 ${base_bindir}/udevadm \
704 ${base_sbindir}/udevadm \
705 ${libexecdir}/${MLPREFIX}udevadm \
706 ${datadir}/bash-completion/completions/udevadm \
707 ${systemd_system_unitdir}/systemd-hwdb-update.service \
708 "
709
710FILES:udev-hwdb = "${rootlibexecdir}/udev/hwdb.d \
711 "
712
713RCONFLICTS:${PN} = "tiny-init ${@bb.utils.contains('PACKAGECONFIG', 'resolved', 'resolvconf', '', d)}"
714
715INITSCRIPT_PACKAGES = "udev"
716INITSCRIPT_NAME:udev = "systemd-udevd"
717INITSCRIPT_PARAMS:udev = "start 03 S ."
718
719python __anonymous() {
720 if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
721 d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
722
723 if bb.utils.contains('PACKAGECONFIG', 'repart', True, False, d) and not bb.utils.contains('PACKAGECONFIG', 'openssl', True, False, d):
724 bb.error("PACKAGECONFIG[repart] requires PACKAGECONFIG[openssl]")
725
726 if bb.utils.contains('PACKAGECONFIG', 'homed', True, False, d) and not bb.utils.contains('PACKAGECONFIG', 'userdb openssl cryptsetup', True, False, d):
727 bb.error("PACKAGECONFIG[homed] requires PACKAGECONFIG[userdb], PACKAGECONFIG[openssl] and PACKAGECONFIG[cryptsetup]")
728}
729
730python do_warn_musl() {
731 if d.getVar('TCLIBC') == "musl":
732 bb.warn("Using systemd with musl is not recommended since it is not supported upstream and some patches are known to be problematic.")
733}
734addtask warn_musl before do_configure
735
736ALTERNATIVE:${PN} = "halt reboot shutdown poweroff runlevel ${@bb.utils.contains('PACKAGECONFIG', 'resolved', 'resolv-conf', '', d)}"
737
738ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd"
739ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf"
740ALTERNATIVE_PRIORITY[resolv-conf] ?= "50"
741
742ALTERNATIVE_TARGET[halt] = "${base_bindir}/systemctl"
743ALTERNATIVE_LINK_NAME[halt] = "${base_sbindir}/halt"
744ALTERNATIVE_PRIORITY[halt] ?= "300"
745
746ALTERNATIVE_TARGET[reboot] = "${base_bindir}/systemctl"
747ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot"
748ALTERNATIVE_PRIORITY[reboot] ?= "300"
749
750ALTERNATIVE_TARGET[shutdown] = "${base_bindir}/systemctl"
751ALTERNATIVE_LINK_NAME[shutdown] = "${base_sbindir}/shutdown"
752ALTERNATIVE_PRIORITY[shutdown] ?= "300"
753
754ALTERNATIVE_TARGET[poweroff] = "${base_bindir}/systemctl"
755ALTERNATIVE_LINK_NAME[poweroff] = "${base_sbindir}/poweroff"
756ALTERNATIVE_PRIORITY[poweroff] ?= "300"
757
758ALTERNATIVE_TARGET[runlevel] = "${base_bindir}/systemctl"
759ALTERNATIVE_LINK_NAME[runlevel] = "${base_sbindir}/runlevel"
760ALTERNATIVE_PRIORITY[runlevel] ?= "300"
761
762pkg_postinst:${PN}:libc-glibc () {
763 sed -e '/^hosts:/s/\s*\<myhostname\>//' \
764 -e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \
765 -i $D${sysconfdir}/nsswitch.conf
766}
767
768pkg_prerm:${PN}:libc-glibc () {
769 sed -e '/^hosts:/s/\s*\<myhostname\>//' \
770 -e '/^hosts:/s/\s*myhostname//' \
771 -i $D${sysconfdir}/nsswitch.conf
772}
773
774PACKAGE_WRITE_DEPS += "qemu-native"
775pkg_postinst:udev-hwdb () {
776 if test -n "$D"; then
777 $INTERCEPT_DIR/postinst_intercept update_udev_hwdb ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX} rootlibexecdir="${rootlibexecdir}" PREFERRED_PROVIDER_udev="${PREFERRED_PROVIDER_udev}"
778 else
779 udevadm hwdb --update
780 fi
781}
782
783pkg_prerm:udev-hwdb () {
784 rm -f $D${sysconfdir}/udev/hwdb.bin
785}