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