summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Jansa <martin.jansa@gmail.com>2012-08-07 09:48:44 +0200
committerEric Bénard <eric@eukrea.com>2012-08-13 10:39:20 +0200
commita4c4a48148368c884dbc57d50195af3806c4aa37 (patch)
tree23c24bc5a539b211b56765319f23d3743194f6e7
parent369bd8bdda774c660756001835737104833389fe (diff)
downloadmeta-openembedded-a4c4a48148368c884dbc57d50195af3806c4aa37.tar.gz
systemd: cleanup /var/run on boot and create /var/run/utmp
* Angstrom uses /var/run cleanup because: Some apps (e.g. avahi-daemon) to clean up their old-style pid files and fail to start every other boot. Se we let systemd clean it on boot. Which seems general enough, so lets move var-run.conf from base-files.bbappend to systemd recipe. * /var/run/utmp was created by volatiles before, but without sysvinit installed systemd-update-utmp-runlevel.service fails to start without this file Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Eric Bénard <eric@eukrea.com>
-rw-r--r--meta-oe/recipes-core/systemd/systemd/var-run.conf4
-rw-r--r--meta-oe/recipes-core/systemd/systemd_git.bb5
2 files changed, 8 insertions, 1 deletions
diff --git a/meta-oe/recipes-core/systemd/systemd/var-run.conf b/meta-oe/recipes-core/systemd/systemd/var-run.conf
new file mode 100644
index 000000000..c2c18e2b9
--- /dev/null
+++ b/meta-oe/recipes-core/systemd/systemd/var-run.conf
@@ -0,0 +1,4 @@
1# empty /var/run
2R /var/run/* - - - - -
3# systemd-update-utmp-runlevel.service fails to start without this
4f /var/run/utmp 0644 root root - -
diff --git a/meta-oe/recipes-core/systemd/systemd_git.bb b/meta-oe/recipes-core/systemd/systemd_git.bb
index f4ca72a12..b9c8a190c 100644
--- a/meta-oe/recipes-core/systemd/systemd_git.bb
+++ b/meta-oe/recipes-core/systemd/systemd_git.bb
@@ -14,7 +14,7 @@ inherit gitpkgv
14PKGV = "v${GITPKGVTAG}" 14PKGV = "v${GITPKGVTAG}"
15 15
16PV = "git" 16PV = "git"
17PR = "r27" 17PR = "r28"
18 18
19inherit useradd pkgconfig autotools vala perlnative 19inherit useradd pkgconfig autotools vala perlnative
20 20
@@ -22,6 +22,7 @@ SRCREV = "3eff4208ffecedd778fec260f0d4b18e94dab443"
22 22
23SRC_URI = "git://anongit.freedesktop.org/systemd/systemd;protocol=git \ 23SRC_URI = "git://anongit.freedesktop.org/systemd/systemd;protocol=git \
24 ${UCLIBCPATCHES} \ 24 ${UCLIBCPATCHES} \
25 file://var-run.conf \
25 " 26 "
26UCLIBCPATCHES = "" 27UCLIBCPATCHES = ""
27UCLIBCPATCHES_libc-uclibc = "file://paper-over-mkostemp.patch \ 28UCLIBCPATCHES_libc-uclibc = "file://paper-over-mkostemp.patch \
@@ -68,6 +69,8 @@ do_install() {
68 # create machine-id 69 # create machine-id
69 # 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 70 # 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
70 touch ${D}${sysconfdir}/machine-id 71 touch ${D}${sysconfdir}/machine-id
72
73 install -m 0644 ${WORKDIR}/var-run.conf ${D}${sysconfdir}/tmpfiles.d/
71} 74}
72 75
73python populate_packages_prepend (){ 76python populate_packages_prepend (){