summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Bergin <peter@berginkonsult.se>2020-09-15 21:33:05 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-09-17 09:47:45 +0100
commit812c2dbabf8349ff5ed6ff8734c4ffea24b0e341 (patch)
tree5b96489d64b948817f95f889e150ac4265d83662
parent70aeecf62da7c0e3b2a0e4110b3c142f7eb374d9 (diff)
downloadpoky-812c2dbabf8349ff5ed6ff8734c4ffea24b0e341.tar.gz
systemd: avoid failing if no udev rules provided
In the case when no udev rules are provided by the recipe the do_install step of systemd is failing with: install: cannot stat '<WORKDIR>/*.rules': No such file or directory By default the systemd recipe provides touchscreen.rules but in the case this is unwanted on target the install step fails. This solution is dynamic and search for *.rules files in $WORKDIR. If found they are installed. (From OE-Core rev: c65eb4c38b61509ad38da19b986e0f06923f0cea) Signed-off-by: Peter Bergin <peter@berginkonsult.se> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/systemd/systemd_246.2.bb4
1 files changed, 3 insertions, 1 deletions
diff --git a/meta/recipes-core/systemd/systemd_246.2.bb b/meta/recipes-core/systemd/systemd_246.2.bb
index 238cd4741f..af10e4212b 100644
--- a/meta/recipes-core/systemd/systemd_246.2.bb
+++ b/meta/recipes-core/systemd/systemd_246.2.bb
@@ -232,7 +232,9 @@ do_install() {
232 232
233 install -d ${D}${sysconfdir}/udev/rules.d/ 233 install -d ${D}${sysconfdir}/udev/rules.d/
234 install -d ${D}${sysconfdir}/tmpfiles.d 234 install -d ${D}${sysconfdir}/tmpfiles.d
235 install -m 0644 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/ 235 for rule in $(find ${WORKDIR} -maxdepth 1 -type f -name "*.rules"); do
236 install -m 0644 $rule ${D}${sysconfdir}/udev/rules.d/
237 done
236 238
237 install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/ 239 install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
238 240