summaryrefslogtreecommitdiff
path: root/system/utmps/APKBUILD
diff options
context:
space:
mode:
authorLaurent Bercot <ska-adelie@skarnet.org>2019-05-28 16:49:42 +0000
committerLaurent Bercot <ska-adelie@skarnet.org>2019-05-28 16:49:42 +0000
commit0b82d071e1d6c87e54e38b8ff5ecd3fb1c5a0c6e (patch)
tree857bb98173718d5ac1ab9fae804cf11677547c55 /system/utmps/APKBUILD
parent2f010c77dd84a08136edf3b38dd5974c6f0b750b (diff)
downloadpackages-0b82d071e1d6c87e54e38b8ff5ecd3fb1c5a0c6e.tar.gz
packages-0b82d071e1d6c87e54e38b8ff5ecd3fb1c5a0c6e.tar.bz2
packages-0b82d071e1d6c87e54e38b8ff5ecd3fb1c5a0c6e.tar.xz
packages-0b82d071e1d6c87e54e38b8ff5ecd3fb1c5a0c6e.zip
system/s6-linux-init: new package = new init system
This commit touches lots of things at once: it is necessary in order to maintain consistency. The impacted packages are: - s6-linux-init: new package. s6-linux-init mechanism plus booting policy. s6-linux-init conflicts with sysvinit; you can have one or the other, depending on what init you want to boot on. * s6-linux-init-common: subpackage of s6-linux-init, containing files used in the s6 supervision tree in both init cases. Both s6-linux-init and sysvinit depend on s6-linux-init-common. - s6: removed s6-svscanboot, which is policy, and only used in the sysvinit case. The s6 package is pure mechanism now. - utmps: adapted to the new location of the supervision tree, and reliable files provided by s6-linux-init-common. It works as is with both init systems. - gettys-openrc: had to move its invocation from "openrc sysinit" to "openrc default", because you can't make early gettys with s6-linux-init (no control over stage 1), and you can't have a supervision tree before sysinit with sysvinit (because /run is mounted very late, in boot), so the only solution that works with both is to make gettys late services. - sysvinit: now has s6-svscanboot (starting the s6 supervision tree from inittab), and a carefully crafted inittab that should work in all cases. Getting the right order of inittab lines was NOT easy, and I now hate sysvinit even more than I did before. Note that with the current version of apk, you cannot switch from sysvinit to s6-linux-init, or vice-versa, without an error. apk says files conflict. Because it adds the new files before removing the old ones. It should still work with apk -f, because the .apk-new mechanism makes it so that there's no real collision while you're switching, but it's still ugly as fuck and needs to be fixed in apk before we make the switch available to users.
Diffstat (limited to 'system/utmps/APKBUILD')
-rw-r--r--system/utmps/APKBUILD20
1 files changed, 11 insertions, 9 deletions
diff --git a/system/utmps/APKBUILD b/system/utmps/APKBUILD
index 9ce4c0dda..78d3a176e 100644
--- a/system/utmps/APKBUILD
+++ b/system/utmps/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Laurent Bercot <ska-adelie@skarnet.org>
pkgname=utmps
pkgver=0.0.2.1
-pkgrel=0
+pkgrel=1
pkgdesc="A secure utmp/wtmp implementation"
url="https://skarnet.org/software/$pkgname/"
arch="all"
@@ -33,12 +33,14 @@ build() {
package() {
cd "$builddir"
make DESTDIR="$pkgdir" install
- mkdir -p -m 0755 "$pkgdir/etc/s6/early-services/utmpd" "$pkgdir/etc/s6/early-services/wtmpd"
- cp -f "$srcdir/utmpd.run" "$pkgdir/etc/s6/early-services/utmpd/run"
- echo 3 > "$pkgdir/etc/s6/early-services/utmpd/notification-fd"
- cp -f "$srcdir/wtmpd.run" "$pkgdir/etc/s6/early-services/wtmpd/run"
- echo 3 > "$pkgdir/etc/s6/early-services/wtmpd/notification-fd"
- chmod 0755 "$pkgdir/etc/s6/early-services/utmpd/run" "$pkgdir/etc/s6/early-services/wtmpd/run"
+ runimage="$pkgdir/etc/s6-linux-init/current/run-image"
+ mkdir -p -m 0755 "$runimage/utmps" "$runimage/service/utmpd" "$runimage/service/wtmpd"
+ chown utmp:utmp "$runimage/utmps"
+ cp -f "$srcdir/utmpd.run" "$runimage/service/utmpd/run"
+ echo 3 > "$runimage/service/utmpd/notification-fd"
+ cp -f "$srcdir/wtmpd.run" "$runimage/service/wtmpd/run"
+ echo 3 > "$runimage/service/wtmpd/notification-fd"
+ chmod 0755 "$runimage/service/utmpd/run" "$runimage/service/wtmpd/run"
}
@@ -75,5 +77,5 @@ doc() {
}
sha512sums="e0ead9dc4085ce778f22831eec0f79ad251c6f5cb83afa6e52a9ab47a4a0037695e70c2ff0624da8b406a8e3c79f0c8653600bc541fad90c4e21d241c53c27aa utmps-0.0.2.1.tar.gz
-525d43e3eced30c564e5390fc715b6caa1ae2b6515a9e3bf01263ff3fb9379bd6908ed302d0d50b6568ac36ed44d272dcc44a683f9ae34d586d8ad17023ed6b1 utmpd.run
-93e4fae527ada9381e0b0a7ad5de9079e8d88959abd74fa5c0710c30c6153832abb010b57ddf83055ca34c032e7e5c9c1eedceb2f122a11ab20837ab66dcf5e2 wtmpd.run"
+0ec30284c64c6ea9f25142c5f4a643bd48b137fe85781b650104f5137ffa4dfc35ca7be3e41e3acd3403ebe1d8c5378073afa4e2f3607d3d794fcd9f98ed51c4 utmpd.run
+cba4f2ec3b8f5becf3ae57eecf584745d783046ee6cf5d116322421ad5ffd074d2955da22d31d2b5b1d05f906378aae92f221d2ac95ac21b54a361fbdc0566e7 wtmpd.run"