From ebff88e4566131a96c47dcbc5c209e5f5137e27a257848b8ab0b3664ec8d291f Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Tue, 14 May 2024 11:52:47 +0000 Subject: [PATCH 1/5] - systemd.spec: some of the meson options have been converted to meson features. OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1519 --- systemd.changes | 5 +++ systemd.spec | 102 +++++++++++++++++++++++++----------------------- 2 files changed, 58 insertions(+), 49 deletions(-) diff --git a/systemd.changes b/systemd.changes index b5531c81..2542c601 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue May 14 11:47:55 UTC 2024 - Franck Bui + +- systemd.spec: some of the meson options have been converted to meson features. + ------------------------------------------------------------------- Mon May 13 09:06:32 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 975f3f26..9e189901 100644 --- a/systemd.spec +++ b/systemd.spec @@ -34,10 +34,10 @@ %define systemd_major %{sub %systemd_version 1 3} %define _testsuitedir %{_systemd_util_dir}/tests -%define xinitconfdir %{?_distconfdir}%{!?_distconfdir:%{_sysconfdir}}/X11/xinit +%define xinitconfdir %{?_distconfdir}%{!?_distconfdir:%{_sysconfdir}}/X11/xinit -# Similar to %%with but returns true/false. The 'true' value can be redefined -# when a second parameter is passed. +# Similar to %%with but return true/false. The value when the condition is +# verified can be redefined when a second parameter is passed. %define __when_1() %{expand:%%{?with_%{1}:true}%%{!?with_%{1}:false}} %define __when_2() %{expand:%%{?with_%{1}:%{2}}%%{!?with_%{1}:false}} %define when() %{expand:%%__when_%# %{*}} @@ -46,6 +46,10 @@ %define __when_not_2() %{expand:%%{?with_%{1}:false}%%{!?with_%{1}:%{2}}} %define when_not() %{expand:%%__when_not_%# %{*}} +# Same as above but return enabled/disabled instead. +%define disabled_with() %{expand:%%{?with_%{1}:disabled}%%{!?with_%{1}:enabled}} +%define enabled_with() %{expand:%%{?with_%{1}:enabled}%%{!?with_%{1}:disabled}} + %if "%{flavor}" == "mini" %global mini -mini %global with_bootstrap 1 @@ -786,70 +790,70 @@ for the C APIs. -Ddebug-shell=/bin/bash \ \ -Dbump-proc-sys-fs-nr-open=false \ - -Ddbus=false \ + -Ddbus=disabled \ -Ddefault-network=false \ - -Dglib=false \ + -Dglib=disabled \ -Dgshadow=false \ -Dldconfig=false \ - -Dlibidn=false \ + -Dlibidn=disabled \ -Dsmack=false \ - -Dxenctrl=false \ - -Dxkbcommon=false \ + -Dxenctrl=disabled \ + -Dxkbcommon=disabled \ \ -Dpstore=true \ \ - -Daudit=%{when_not bootstrap} \ - -Dbpf-framework=%{when_not bootstrap} \ - -Dbzip2=%{when importd} \ + -Daudit=%{disabled_with bootstrap} \ + -Dbpf-framework=%{disabled_with bootstrap} \ + -Dbzip2=%{enabled_with importd} \ -Defi=%{when_not bootstrap} \ - -Delfutils=%{when_not bootstrap} \ - -Dfdisk=%{when_not bootstrap} \ - -Dgcrypt=%{when_not bootstrap} \ - -Dgnutls=%{when_not bootstrap} \ - -Dhtml=%{when_not bootstrap} \ + -Delfutils=%{disabled_with bootstrap} \ + -Dfdisk=%{disabled_with bootstrap} \ + -Dgcrypt=%{disabled_with bootstrap} \ + -Dgnutls=%{disabled_with bootstrap} \ + -Dhtml=%{disabled_with bootstrap} \ -Dima=%{when_not bootstrap} \ -Dkernel-install=%{when_not bootstrap} \ - -Dlibfido2=%{when_not bootstrap} \ - -Dlibidn2=%{when resolved} \ - -Dlibiptc=%{when_not bootstrap} \ - -Dlz4=%{when_not bootstrap} \ - -Dqrencode=%{when_not bootstrap} \ - -Dkmod=%{when_not bootstrap} \ - -Dlibcryptsetup=%{when_not bootstrap} \ - -Dlibcryptsetup-plugins=%{when_not bootstrap} \ - -Dlibcurl=%{when_not bootstrap} \ - -Dman=%{when_not bootstrap} \ - -Dmicrohttpd=%{when journal_remote} \ + -Dlibfido2=%{disabled_with bootstrap} \ + -Dlibidn2=%{enabled_with resolved} \ + -Dlibiptc=%{disabled_with bootstrap} \ + -Dlz4=%{disabled_with bootstrap} \ + -Dqrencode=%{disabled_with bootstrap} \ + -Dkmod=%{disabled_with bootstrap} \ + -Dlibcryptsetup=%{disabled_with bootstrap} \ + -Dlibcryptsetup-plugins=%{disabled_with bootstrap} \ + -Dlibcurl=%{disabled_with bootstrap} \ + -Dman=%{disabled_with bootstrap} \ + -Dmicrohttpd=%{enabled_with journal_remote} \ -Dnss-myhostname=%{when_not bootstrap} \ - -Dnss-mymachines=%{when machined} \ - -Dnss-resolve=%{when resolved} \ + -Dnss-mymachines=%{enabled_with machined} \ + -Dnss-resolve=%{enabled_with resolved} \ -Dnss-systemd=%{when_not bootstrap} \ - -Dopenssl=%{when_not bootstrap} \ - -Dp11kit=%{when_not bootstrap} \ - -Dpasswdqc=%{when_not bootstrap} \ - -Dpwquality=%{when_not bootstrap} \ - -Dseccomp=%{when_not bootstrap} \ - -Drepart=%{when_not bootstrap} \ + -Dopenssl=%{disabled_with bootstrap} \ + -Dp11kit=%{disabled_with bootstrap} \ + -Dpasswdqc=%{disabled_with bootstrap} \ + -Dpwquality=%{disabled_with bootstrap} \ + -Dseccomp=%{disabled_with bootstrap} \ + -Drepart=%{disabled_with bootstrap} \ -Dstoragetm=%{when_not bootstrap} \ -Dtpm=%{when_not bootstrap} \ - -Dtpm2=%{when_not bootstrap} \ + -Dtpm2=%{disabled_with bootstrap} \ -Dtranslations=%{when_not bootstrap} \ -Duserdb=%{when_not bootstrap} \ - -Dxz=%{when_not bootstrap} \ - -Dzlib=%{when importd} \ - -Dzstd=%{when_not bootstrap} \ + -Dxz=%{disabled_with bootstrap} \ + -Dzlib=%{enabled_with importd} \ + -Dzstd=%{disabled_with bootstrap} \ \ - -Dapparmor=%{when apparmor} \ + -Dapparmor=%{enabled_with apparmor} \ -Dcoredump=%{when coredump} \ - -Dhomed=%{when homed} \ - -Dimportd=%{when importd} \ + -Dhomed=%{enabled_with homed} \ + -Dimportd=%{enabled_with importd} \ -Dmachined=%{when machined} \ -Dnetworkd=%{when networkd} \ -Dportabled=%{when portabled} \ - -Dremote=%{when journal_remote} \ - -Dselinux=%{when selinux} \ + -Dremote=%{enabled_with journal_remote} \ + -Dselinux=%{enabled_with selinux} \ \ - -Dbootloader=%{when sd_boot} \ + -Dbootloader=%{enabled_with sd_boot} \ -Defi-color-highlight="black,green" \ \ -Dsbat-distro="%{?sbat_distro}" \ @@ -865,13 +869,13 @@ for the C APIs. -Dresolve=%{when resolved} \ \ -Doomd=%{when experimental} \ - -Dsysupdate=%{when experimental} \ + -Dsysupdate=%{enabled_with experimental} \ %if %{with sd_boot} - -Dukify=%{when experimental} \ + -Dukify=%{enabled_with experimental} \ %else - -Dukify=false \ + -Dukify=disabled \ %endif - -Dvmspawn=%{when experimental} \ + -Dvmspawn=%{enabled_with experimental} \ \ -Dtests=%{when testsuite unsafe} \ -Dinstall-tests=%{when testsuite} From fc3c5b8fc92c24b9aa1361a5fbd4cd9a1b6d4d2fbdecea08b0729377b3059b96 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Wed, 15 May 2024 08:10:08 +0000 Subject: [PATCH 2/5] - systemd.spec: update the minimal required version of dracut. Also drop conflicts with mkinitrd: this package has been removed since quite some time now. OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1520 --- systemd.changes | 7 +++++++ systemd.spec | 4 +--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/systemd.changes b/systemd.changes index 2542c601..3bfbc243 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed May 15 08:05:43 UTC 2024 - Franck Bui + +- systemd.spec: update the minimal required version of dracut. Also drop + conflicts with mkinitrd: this package has been removed since quite some time + now. + ------------------------------------------------------------------- Tue May 14 11:47:55 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 9e189901..d54003dd 100644 --- a/systemd.spec +++ b/systemd.spec @@ -172,7 +172,6 @@ Recommends: libbpf1 %endif Provides: group(systemd-journal) Conflicts: filesystem < 11.5 -Conflicts: mkinitrd < 2.7.0 Provides: sbin_init Provides: sysvinit:/sbin/init Conflicts: sbin_init @@ -367,9 +366,8 @@ Recommends: libtss2-mu0 Recommends: libtss2-rc0 %endif Conflicts: ConsoleKit < 0.4.1 -Conflicts: dracut < 044.1 +Conflicts: dracut < 059 Conflicts: filesystem < 11.5 -Conflicts: mkinitrd < 2.7.0 Conflicts: util-linux < 2.16 %if %{with bootstrap} Conflicts: udev From 7b1278ac37d0b8204f6195b6930cd8e25a3cd09b68ea5790a8d9352c007b1a9a Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Thu, 16 May 2024 08:48:39 +0000 Subject: [PATCH 3/5] - Import commit 3ea0e1dff3d7ca74c072cdcc8b371034125803d6 3ea0e1dff3 test/test-rpm-macros.sh: add build directory to pkg-config search path 1cbf1c82b5 libsystemd-network: skip dhcp server test in case of EAFNOSUPPORT 38f7ac60db sd-event: increase test-event timeout to 120s OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1521 --- systemd-v255.6+suse.27.ga3dccacb97.tar.xz | 3 --- systemd-v255.6+suse.30.g3ea0e1dff3.tar.xz | 3 +++ systemd.changes | 9 +++++++++ systemd.spec | 2 +- 4 files changed, 13 insertions(+), 4 deletions(-) delete mode 100644 systemd-v255.6+suse.27.ga3dccacb97.tar.xz create mode 100644 systemd-v255.6+suse.30.g3ea0e1dff3.tar.xz diff --git a/systemd-v255.6+suse.27.ga3dccacb97.tar.xz b/systemd-v255.6+suse.27.ga3dccacb97.tar.xz deleted file mode 100644 index e063d8b2..00000000 --- a/systemd-v255.6+suse.27.ga3dccacb97.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:cd94c03570eb206aa3895e95762db838a47d669d1b88fcacc4ac664da2de3162 -size 10844048 diff --git a/systemd-v255.6+suse.30.g3ea0e1dff3.tar.xz b/systemd-v255.6+suse.30.g3ea0e1dff3.tar.xz new file mode 100644 index 00000000..245a22fc --- /dev/null +++ b/systemd-v255.6+suse.30.g3ea0e1dff3.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:be22e57b7012fb5b7f54c2daf980a3f8a8ed0890759b529c1baa0a2d3bb6ff2c +size 10843156 diff --git a/systemd.changes b/systemd.changes index 3bfbc243..b7b37a22 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Thu May 16 08:27:27 UTC 2024 - Franck Bui + +- Import commit 3ea0e1dff3d7ca74c072cdcc8b371034125803d6 + + 3ea0e1dff3 test/test-rpm-macros.sh: add build directory to pkg-config search path + 1cbf1c82b5 libsystemd-network: skip dhcp server test in case of EAFNOSUPPORT + 38f7ac60db sd-event: increase test-event timeout to 120s + ------------------------------------------------------------------- Wed May 15 08:05:43 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index d54003dd..116862d1 100644 --- a/systemd.spec +++ b/systemd.spec @@ -28,7 +28,7 @@ %else %define systemd_version 255.6 %define systemd_release 0 -%define archive_version +suse.27.ga3dccacb97 +%define archive_version +suse.30.g3ea0e1dff3 %endif %define systemd_major %{sub %systemd_version 1 3} From d09e66c09eb82d6f5313c9f144785c34c22d285d5ad39f37bee5557be608fc66 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Thu, 16 May 2024 14:23:48 +0000 Subject: [PATCH 4/5] Accepting request 1174450 from home:radolin:branches:Base:System - systemd.spec: enable tests during build OBS-URL: https://build.opensuse.org/request/show/1174450 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1522 --- systemd.changes | 5 +++++ systemd.spec | 9 +++++++++ 2 files changed, 14 insertions(+) diff --git a/systemd.changes b/systemd.changes index b7b37a22..9b7eaed4 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu May 16 10:01:20 UTC 2024 - Radoslav Kolev + +- systemd.spec: enable tests during build + ------------------------------------------------------------------- Thu May 16 08:27:27 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 116862d1..3ed01092 100644 --- a/systemd.spec +++ b/systemd.spec @@ -139,6 +139,11 @@ BuildRequires: pam-devel BuildRequires: python3-Jinja2 BuildRequires: systemd-rpm-macros BuildRequires: pkgconfig(blkid) >= 2.26 +#The following packages are only required by the tests during %check +BuildRequires: acl +BuildRequires: distribution-release +BuildRequires: python3-pefile +BuildRequires: timezone %if %{with bootstrap} #!BuildIgnore: dbus-1 @@ -1089,6 +1094,10 @@ rm -fr %{buildroot}%{_docdir}/systemd %systemd_pre systemd-journald-audit.socket %systemd_pre systemd-userdbd.service +#Execute the tests +%check +%meson_test + %post if [ $1 -eq 1 ]; then # Make /etc/machine-id an empty file during package installation. On the From aea07c1d293bb964680ce558678b81078b84f9839e83a7285503ccbbdc60e165 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Thu, 16 May 2024 14:28:26 +0000 Subject: [PATCH 5/5] emphasize that it's the *unit* tests that are run in %check OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1523 --- systemd.changes | 2 +- systemd.spec | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/systemd.changes b/systemd.changes index 9b7eaed4..6ac38856 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,7 +1,7 @@ ------------------------------------------------------------------- Thu May 16 10:01:20 UTC 2024 - Radoslav Kolev -- systemd.spec: enable tests during build +- systemd.spec: enable unit tests during build ------------------------------------------------------------------- Thu May 16 08:27:27 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 3ed01092..7c73a51d 100644 --- a/systemd.spec +++ b/systemd.spec @@ -139,7 +139,7 @@ BuildRequires: pam-devel BuildRequires: python3-Jinja2 BuildRequires: systemd-rpm-macros BuildRequires: pkgconfig(blkid) >= 2.26 -#The following packages are only required by the tests during %check +# The following packages are only required by the execution of the unit tests during %%check BuildRequires: acl BuildRequires: distribution-release BuildRequires: python3-pefile @@ -1094,8 +1094,8 @@ rm -fr %{buildroot}%{_docdir}/systemd %systemd_pre systemd-journald-audit.socket %systemd_pre systemd-userdbd.service -#Execute the tests %check +# Run the unit tests. %meson_test %post