Christian Hesse pushed to branch main at Arch Linux / Packaging / Packages / systemd
Commits: 4d1ecb08 by Daan De Meyer at 2024-03-22T15:43:45+01:00 Various changes to support building from upstream sources - The pkgrel doesn't make much sense when building for upstream as it will never change so omit it from the version tags. This also allows us to start using the date for the version tag to ensure any package we build from upstream always has a higher version than previous builds without triggering unnecessary rebuilds (changing version-tag triggers rebuilds of many meson targets as they depend on the version tag). - Add libarchive dependency when building for upstream as the libarchive was added as an optional dependency in https://github.com/systemd/systemd/pull/31075 so when we're building for upstream let's pull it in as a dependency. - Add support for setting QUIET=1 which allows configuring verbose or quiet meson operation with the QUIET environment variable. - Allow specifying extra meson configure options via an environment variable - Build in developer mode when UPSTREAM=1. This enables some experimental components such as systemd-vmspawn and enables various options that are useful for debugging. - - - - - 1 changed file: - PKGBUILD Changes: ===================================== PKGBUILD ===================================== @@ -72,6 +72,23 @@ sha512sums=('0c41c21931c5f08b5c91fe718d90f8cb11fb83429b3028bde9922605a35ea81d845 'a50d202a9c2e91a4450b45c227b295e1840cc99a5e545715d69c8af789ea3dd95a03a30f050d52855cabdc9183d4688c1b534eaa755ebe93616f9d192a855ee3' '825b9dd0167c072ba62cabe0677e7cd20f2b4b850328022540f122689d8b25315005fa98ce867cf6e7460b2b26df16b88bb3b5c9ebf721746dce4e2271af7b97') +_meson_version="${pkgver}-${pkgrel}" +_meson_mode='release' +_meson_compile=() +_meson_install=() + +if ((UPSTREAM)); then + _meson_version="${pkgver}" + _meson_mode='developer' + makedepends+=('libarchive') + optdepends_upstream=('libarchive: convert DDIs to tarballs') + if ((QUIET)); then + _meson_install=('--quiet') + else + _meson_compile=('--verbose') + fi +fi + _backports=( ) @@ -116,11 +133,11 @@ build() { ) local _meson_options=( - -Dversion-tag="${_tag_name}-${pkgrel}-arch" + -Dversion-tag="${_meson_version}-arch" # We use the version without tildes as the shared library tag because # pacman looks at the shared library version. - -Dshared-lib-tag="${pkgver}-${pkgrel}" - -Dmode=release + -Dshared-lib-tag="${_meson_version/~/}" + -Dmode="${_meson_mode}" -Dapparmor=false -Dbootloader=true @@ -158,9 +175,9 @@ build() { -Dsbat-distro-url="https://archlinux.org/packages/core/x86_64/${pkgname}/" ) - arch-meson "$pkgbase-stable" build "${_meson_options[@]}" + arch-meson "$pkgbase-stable" build "${_meson_options[@]}" $MESON_EXTRA_CONFIGURE_OPTIONS - meson compile -C build + meson compile -C build "${_meson_compile[@]}" } check() { @@ -197,6 +214,7 @@ package_systemd() { 'libfido2: unlocking LUKS2 volumes with FIDO2 token' 'libp11-kit: support PKCS#11' 'tpm2-tss: unlocking LUKS2 volumes with TPM2') + optdepends+=("${_optdepends_upstream[@]}") backup=(etc/pam.d/systemd-user etc/systemd/coredump.conf etc/systemd/homed.conf @@ -216,7 +234,7 @@ package_systemd() { etc/udev/udev.conf) install=systemd.install - meson install -C build --destdir "$pkgdir" + meson install -C build --destdir "$pkgdir" "${_meson_install[@]}" # we'll create this on installation rmdir "$pkgdir"/var/log/journal/remote View it on GitLab: https://gitlab.archlinux.org/archlinux/packaging/packages/systemd/-/commit/4d1ecb083589270e9137c8bd3838e6b73bfdbff7 -- View it on GitLab: https://gitlab.archlinux.org/archlinux/packaging/packages/systemd/-/commit/4d1ecb083589270e9137c8bd3838e6b73bfdbff7 You're receiving this email because of your account on gitlab.archlinux.org.