From de9857c4a951af478d540ec0cba761d3c9f951e843d3abf8f8b0230be8cc5ef7 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Tue, 20 Feb 2024 14:38:41 +0000 Subject: [PATCH 1/2] Accepting request 1148086 from home:daandemeyer:branches:Base:System - Add a new %upstream macro to support building from upstream sources. This will allow upstream to build systemd rpms using the opensuse systemd packaging specs. These rpms will be built and used in upstream's mkosi based hacking and testing environment to test changes and in the future to run integration tests as well. By building the rpms using the opensuse packaging specs, the idea is to catch more issues ahead of time as the mkosi environment will behave more like a regular opensuse system. - Add new %version_override and %version_release macros to allow overriding the version and release of the rpm respectively. OBS-URL: https://build.opensuse.org/request/show/1148086 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1494 --- files.experimental | 8 ++++++++ files.network | 4 ++++ files.systemd | 4 ++-- systemd.changes | 13 +++++++++++++ systemd.spec | 40 ++++++++++++++++++++++++++++++++++------ 5 files changed, 61 insertions(+), 8 deletions(-) diff --git a/files.experimental b/files.experimental index 73303174..aa23c6ac 100644 --- a/files.experimental +++ b/files.experimental @@ -32,7 +32,11 @@ %{_mandir}/man8/systemd-pcrmachine.service.8.gz %{_mandir}/man8/systemd-pcrphase-initrd.service.8.gz %{_mandir}/man8/systemd-pcrphase-sysinit.service.8.gz +%if %{with upstream} +%{_mandir}/man8/systemd-pcrextend.8.gz +%else %{_mandir}/man8/systemd-pcrphase.8.gz +%endif %{_mandir}/man8/systemd-pcrphase.service.8.gz %endif %{_mandir}/man8/systemd-repart.8.gz @@ -53,8 +57,12 @@ %endif %{_systemd_util_dir}/systemd-oomd %if %{with sd_boot} +%if %{with upstream} +%{_systemd_util_dir}/systemd-pcrextend +%else %{_systemd_util_dir}/systemd-pcrphase %endif +%endif %{_systemd_util_dir}/systemd-sysupdate %{_systemd_util_dir}/systemd-userwork %if %{with sd_boot} diff --git a/files.network b/files.network index e28d4826..60867129 100644 --- a/files.network +++ b/files.network @@ -31,7 +31,11 @@ %{_systemd_util_dir}/network/80-container-vb.network %{_systemd_util_dir}/network/80-container-ve.network %{_systemd_util_dir}/network/80-container-vz.network +%if %{with upstream} +%{_systemd_util_dir}/network/89-ethernet.network.example +%else %{_systemd_util_dir}/network/80-ethernet.network.example +%endif %{_systemd_util_dir}/network/80-vm-vt.network %{_systemd_util_dir}/network/80-wifi-adhoc.network %{_systemd_util_dir}/network/80-wifi-ap.network.example diff --git a/files.systemd b/files.systemd index ba740265..4838f6ba 100644 --- a/files.systemd +++ b/files.systemd @@ -209,8 +209,8 @@ %{_libdir}/libnss_myhostname.so.2 %{_libdir}/libnss_systemd.so.2 %endif -%{_libdir}/systemd/libsystemd-core-254.so -%{_libdir}/systemd/libsystemd-shared-254.so +%{_libdir}/systemd/libsystemd-core-*.so +%{_libdir}/systemd/libsystemd-shared-*.so %if %{without bootstrap} %{_mandir}/man1/busctl.1.gz %{_mandir}/man1/hostnamectl.1.gz diff --git a/systemd.changes b/systemd.changes index 28630f23..ac25d2f5 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Tue Feb 20 12:22:42 UTC 2024 - Daan De Meyer + +- Add a new %upstream macro to support building from upstream sources. This + will allow upstream to build systemd rpms using the opensuse systemd packaging + specs. These rpms will be built and used in upstream's mkosi based hacking and + testing environment to test changes and in the future to run integration tests + as well. By building the rpms using the opensuse packaging specs, the idea is + to catch more issues ahead of time as the mkosi environment will behave more + like a regular opensuse system. +- Add new %version_override and %version_release macros to allow overriding the + version and release of the rpm respectively. + ------------------------------------------------------------------- Mon Feb 19 08:53:31 UTC 2024 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 4d4d15b5..488154d0 100644 --- a/systemd.spec +++ b/systemd.spec @@ -20,6 +20,17 @@ %define archive_version +suse.28.g53e2aaaf9d +%if 0%{?version_override} +%define systemd_major %version_override +%define systemd_minor %{nil} +%else +%define systemd_major 254 +%define systemd_minor 1 +%endif + +%define systemd_version %{systemd_major}%{?systemd_minor:.%{systemd_minor}} +%define systemd_release %{?release_override}%{!?release_override:0} + %define _testsuitedir %{_systemd_util_dir}/tests %define xinitconfdir %{?_distconfdir}%{!?_distconfdir:%{_sysconfdir}}/X11/xinit @@ -58,6 +69,8 @@ %bcond_without testsuite %endif +%bcond_with upstream + # The following features are kept to ease migrations toward SLE. Their default # value is independent of the build flavor. %bcond_without filetriggers @@ -79,8 +92,10 @@ fi \ Name: systemd%{?mini} URL: http://www.freedesktop.org/wiki/Software/systemd -Version: 254.9 -Release: 0 +# Allow users to specify the version and release when building the rpm by +# setting the %version_override and %release_override macros. +Version: %systemd_version +Release: %systemd_release Summary: A System and Session Manager License: LGPL-2.1-or-later BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -215,6 +230,8 @@ Patch4: 0002-rc-local-fix-ordering-startup-for-etc-init.d-boot.lo.patch Patch5: 0008-sysv-generator-translate-Required-Start-into-a-Wants.patch %endif +%if %{without upstream} + # Patches listed below are put in quarantine. Normally all changes must go to # upstream first and then are cherry-picked in the SUSE git repository. But for # very few cases, some stuff might be broken in upstream and need to be fixed or @@ -232,6 +249,8 @@ Patch5008: 5008-test-Add-effective-cgroup-limits-testing.patch Patch5009: 5009-cgroup-Restrict-effective-limits-with-global-resourc.patch Patch5010: 5010-cgroup-Rename-effective-limits-internal-table.patch +%endif + %description Systemd is a system and service manager, compatible with SysV and LSB init scripts for Linux. systemd provides aggressive parallelization @@ -357,6 +376,15 @@ Conflicts: util-linux < 2.16 Conflicts: udev Provides: udev = %{version}-%{release} %endif +%if %{with upstream} +BuildRequires: pkgconfig(xencontrol) +BuildRequires: pkgconfig(libarchive) +BuildRequires: pkgconfig(xkbcommon) +BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(dbus-1) +Recommends: libarchive13 +Recommends: libxkbcommon0 +%endif %description -n udev%{?mini} This package provides systemd-udevd. The udev daemon receives device uevents @@ -722,7 +750,7 @@ export CFLAGS="%{optflags} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" %meson \ -Dmode=release \ - -Dversion-tag=%{version}%{archive_version} \ + -Dversion-tag=%{version}%[%{without upstream}?"%{archive_version}":""] \ -Ddocdir=%{_docdir}/systemd \ %if %{with split_usr} -Drootprefix=/usr \ @@ -799,7 +827,7 @@ export CFLAGS="%{optflags} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" -Dsbat-distro-url="%{?sbat_distro_url}" \ \ -Dsbat-distro-pkgname="%{name}" \ - -Dsbat-distro-version="%{version}-%{release}" \ + -Dsbat-distro-version="%{version}%[%{without upstream}?"-%{release}":""]" \ \ -Ddefault-dnssec=no \ -Ddns-servers='' \ @@ -1387,13 +1415,13 @@ fi %defattr(-,root,root) %license LICENSE.LGPL2.1 %{_libdir}/libsystemd.so.0 -%{_libdir}/libsystemd.so.0.37.0 +%{_libdir}/libsystemd.so.0.*.0 %files -n libudev%{?mini}1 %defattr(-,root,root) %license LICENSE.LGPL2.1 %{_libdir}/libudev.so.1 -%{_libdir}/libudev.so.1.7.7 +%{_libdir}/libudev.so.1.7.* %if %{with coredump} %files coredump From 60821ed2c5443e1fff86c7fb080ad5ac5928faf33fd79484ccd548a8a7b10425 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Thu, 22 Feb 2024 10:10:39 +0000 Subject: [PATCH 2/2] - Import commit 31f1148f75a1155d3eb37fd1a450096d669ec65b 31f1148f75 seccomp: include `fchmodat2` in `@file-system` (bsc#1219766) 001f349c57 service: Demote log level of NotifyAccess= messages to debug (bsc#1210113 jsc#PED-6214) OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1495 --- systemd-v254.9+suse.28.g53e2aaaf9d.tar.xz | 3 --- systemd-v254.9+suse.30.g31f1148f75.tar.xz | 3 +++ systemd.changes | 8 ++++++++ systemd.spec | 14 +++++++------- 4 files changed, 18 insertions(+), 10 deletions(-) delete mode 100644 systemd-v254.9+suse.28.g53e2aaaf9d.tar.xz create mode 100644 systemd-v254.9+suse.30.g31f1148f75.tar.xz diff --git a/systemd-v254.9+suse.28.g53e2aaaf9d.tar.xz b/systemd-v254.9+suse.28.g53e2aaaf9d.tar.xz deleted file mode 100644 index 48a9e1c4..00000000 --- a/systemd-v254.9+suse.28.g53e2aaaf9d.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0923da810cbcc9246fec9bab9be46d497511a5117e001e3b7c570df9dd5c1cc2 -size 10409356 diff --git a/systemd-v254.9+suse.30.g31f1148f75.tar.xz b/systemd-v254.9+suse.30.g31f1148f75.tar.xz new file mode 100644 index 00000000..20d19563 --- /dev/null +++ b/systemd-v254.9+suse.30.g31f1148f75.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:67af3a7f3c6bd95e677f8bbae803429f8f1b1a7e282d31645620f7740556f29f +size 10407004 diff --git a/systemd.changes b/systemd.changes index ac25d2f5..8f2452b3 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Thu Feb 22 09:47:41 UTC 2024 - Franck Bui + +- Import commit 31f1148f75a1155d3eb37fd1a450096d669ec65b + + 31f1148f75 seccomp: include `fchmodat2` in `@file-system` (bsc#1219766) + 001f349c57 service: Demote log level of NotifyAccess= messages to debug (bsc#1210113 jsc#PED-6214) + ------------------------------------------------------------------- Tue Feb 20 12:22:42 UTC 2024 - Daan De Meyer diff --git a/systemd.spec b/systemd.spec index 488154d0..bfd83789 100644 --- a/systemd.spec +++ b/systemd.spec @@ -18,14 +18,14 @@ %global flavor @BUILD_FLAVOR@%{nil} -%define archive_version +suse.28.g53e2aaaf9d +%define archive_version +suse.30.g31f1148f75 %if 0%{?version_override} %define systemd_major %version_override %define systemd_minor %{nil} %else %define systemd_major 254 -%define systemd_minor 1 +%define systemd_minor 9 %endif %define systemd_version %{systemd_major}%{?systemd_minor:.%{systemd_minor}} @@ -93,7 +93,7 @@ fi \ Name: systemd%{?mini} URL: http://www.freedesktop.org/wiki/Software/systemd # Allow users to specify the version and release when building the rpm by -# setting the %version_override and %release_override macros. +# setting the %%version_override and %%release_override macros. Version: %systemd_version Release: %systemd_release Summary: A System and Session Manager @@ -377,11 +377,11 @@ Conflicts: udev Provides: udev = %{version}-%{release} %endif %if %{with upstream} -BuildRequires: pkgconfig(xencontrol) -BuildRequires: pkgconfig(libarchive) -BuildRequires: pkgconfig(xkbcommon) -BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(dbus-1) +BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(libarchive) +BuildRequires: pkgconfig(xencontrol) +BuildRequires: pkgconfig(xkbcommon) Recommends: libarchive13 Recommends: libxkbcommon0 %endif