From 759d6c67015cb85f9dde963a640eb01e33415777 Mon Sep 17 00:00:00 2001 From: Aelin Date: Tue, 2 Jun 2026 03:10:42 +0200 Subject: [PATCH] systemd/systemd-stage0: provide pc:libsystemd See the comment in the APKBUILD for the details. Closes #4156 Tweak by Oliver: set provider_priority=1 explicitly, so the CI script passes. systemd proper has provider_priority=100 for the dev() subpackage. Signed-off-by: Oliver Smith Part-of: --- extra-repos/systemd/systemd-stage0/APKBUILD | 21 ++++++++++++++++++++- extra-repos/systemd/systemd/APKBUILD | 2 +- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/extra-repos/systemd/systemd-stage0/APKBUILD b/extra-repos/systemd/systemd-stage0/APKBUILD index dee923f4c..da5b58242 100644 --- a/extra-repos/systemd/systemd-stage0/APKBUILD +++ b/extra-repos/systemd/systemd-stage0/APKBUILD @@ -6,7 +6,7 @@ pkgname=systemd-stage0 pkgver=261_rc2 _pkgver="${pkgver/_/-}" # pkgrel must match systemd! -pkgrel=1 +pkgrel=2 pkgdesc="Minimal systemd bootstrap package" url="https://github.com/systemd/systemd" # armhf: pmb#2618 @@ -103,6 +103,25 @@ build() { meson compile ${JOBS:+-j ${JOBS}} -C build } +dev() { + default_dev + + # Since we set !tracedeps, we must explicitly list things we want this + # package to provide. We mainly need systemd-stage0 to build dbus, which + # we then use to build the "real" systemd. We do not want to re-compile + # dbus afterwards, dbus-dev should pull in libsystemd. + # If we don't explicitly provide pc:libsystemd here, building dbus + # against systemd-stage0 would result in the following abuild log: + # "Could not find any provider for pc:libsystemd>=209" + # and dbus-dev would not depend on libsystemd. + # If systemd-stage0-dev provides pc:libsystemd, this is solved and + # dbus-dev correctly depends on pc:libsystemd. And yes, this is only + # necessary because of !tracedeps. + # See pma#4156 for the bootstrap issue this solves. + provides="$provides pc:libsystemd=${pkgver%%[._]*}" + provider_priority=1 +} + package() { DESTDIR="$pkgdir" meson install --no-rebuild -C build } diff --git a/extra-repos/systemd/systemd/APKBUILD b/extra-repos/systemd/systemd/APKBUILD index 8fa67a7d1..eb655e1c2 100644 --- a/extra-repos/systemd/systemd/APKBUILD +++ b/extra-repos/systemd/systemd/APKBUILD @@ -10,7 +10,7 @@ pkgname=systemd pkgver=261_rc2 _pkgver="${pkgver/_/-}" # pkgrel must match systemd-stage0! -pkgrel=1 +pkgrel=2 pkgdesc="System and service manager" url="https://github.com/systemd/systemd" # armhf: no linux-stable