From 96b3e780700c351f85fa180dcb0d536dfd1ec094702c3573b53c5c3e0ccd75dc Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Tue, 28 Apr 2020 07:44:28 +0000 Subject: [PATCH 1/2] Accepting request 798553 from home:fbui:systemd:openSUSE-Factory - Drop legacy /sbin/{udevd,udevadm) symlinks hopefully for good Since boo#1160890 has been fixed since a couple of months now. - Drop content of /usr/share/factory/ (bsc#1170146) systemd ships several files in /usr/share/factory/etc that are copied to /etc in case those files are missing there. Unfortunately the content does not match the openSUSE defaults. - Drop most of the tmpfiles that deal with generic paths (bsc#1078466) They are problematic because some of them conflict with SUSE defaults. Therefore it seems better to let the revelant packages owning these paths to provide their own definitions instead. OBS-URL: https://build.opensuse.org/request/show/798553 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1097 --- ...lock-group-to-follow-openSUSE-policy.patch | 38 ----------------- ...E-policy-do-not-clean-tmp-by-default.patch | 26 ------------ systemd-mini.changes | 25 +++++++++++ systemd-mini.spec | 42 ++++++++++++++----- systemd.changes | 25 +++++++++++ systemd.spec | 42 ++++++++++++++----- tmpfiles-suse.conf | 15 +++++++ 7 files changed, 127 insertions(+), 86 deletions(-) delete mode 100644 0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch delete mode 100644 0001-SUSE-policy-do-not-clean-tmp-by-default.patch create mode 100644 tmpfiles-suse.conf diff --git a/0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch b/0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch deleted file mode 100644 index 66eeece9..00000000 --- a/0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch +++ /dev/null @@ -1,38 +0,0 @@ -From ca2788b478d763e49d2463378272d9fef2ef1bf3 Mon Sep 17 00:00:00 2001 -From: Franck Bui -Date: Mon, 9 May 2016 16:10:21 +0200 -Subject: [PATCH 1/1] Fix /run/lock group to follow openSUSE policy - -This is a partial import of commit -88013cabb939e4bd7347ce324c9eb9c1a45582de part of SUSE/v210 branch. - -However /var/lock/{subsys,lockdev} are left alone and will be created -because: - -- a bug was opened requesting /var/lock/subsys, see commit -0671c57670fc09e0cb970d081a1b523ea9c62b5b. - -- creating /var/lock/lockdev shouldn't hurt. - -[fixes: bnc#733523] ---- - tmpfiles.d/legacy.conf | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/tmpfiles.d/legacy.conf b/tmpfiles.d/legacy.conf -index 62e2ae0986..415918f407 100644 ---- a/tmpfiles.d/legacy.conf -+++ b/tmpfiles.d/legacy.conf -@@ -10,7 +10,8 @@ - # These files are considered legacy and are unnecessary on legacy-free - # systems. - --d /run/lock 0755 root root - -+# On openSUSE, /run/lock is owned by the 'lock' group. -+d /run/lock 0775 root lock - - L /var/lock - - - - ../run/lock - - # /run/lock/subsys is used for serializing SysV service execution, and --- -2.16.4 - diff --git a/0001-SUSE-policy-do-not-clean-tmp-by-default.patch b/0001-SUSE-policy-do-not-clean-tmp-by-default.patch deleted file mode 100644 index 6f37b2d6..00000000 --- a/0001-SUSE-policy-do-not-clean-tmp-by-default.patch +++ /dev/null @@ -1,26 +0,0 @@ -From b66a7b4b5aa25a1ffb4b76fe9545046dabd92c03 Mon Sep 17 00:00:00 2001 -From: Reinhard Max -Date: Fri, 19 Apr 2013 16:56:26 +0200 -Subject: [PATCH 1/1] SUSE policy: do not clean /tmp by default. - -Fix regression in the default for tmp auto-deletion (FATE#314974). ---- - tmpfiles.d/tmp.conf | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -diff --git a/tmpfiles.d/tmp.conf b/tmpfiles.d/tmp.conf -index fe5225d751..dedc7569e1 100644 ---- a/tmpfiles.d/tmp.conf -+++ b/tmpfiles.d/tmp.conf -@@ -8,5 +8,6 @@ - # See tmpfiles.d(5) for details - - # Clear tmp directories separately, to make them easier to override --q /tmp 1777 root root 10d --q /var/tmp 1777 root root 30d -+# SUSE policy: we don't clean those directories -+q /tmp 1777 root root - -+q /var/tmp 1777 root root - --- -2.16.4 - diff --git a/systemd-mini.changes b/systemd-mini.changes index ad86ea9d..fa100f54 100644 --- a/systemd-mini.changes +++ b/systemd-mini.changes @@ -1,3 +1,28 @@ +------------------------------------------------------------------- +Mon Apr 27 15:45:50 UTC 2020 - Franck Bui + +- Drop legacy /sbin/{udevd,udevadm) symlinks hopefully for good + + Since boo#1160890 has been fixed since a couple of months now. + +------------------------------------------------------------------- +Mon Apr 27 14:50:36 UTC 2020 - Franck Bui + +- Drop content of /usr/share/factory/ (bsc#1170146) + + systemd ships several files in /usr/share/factory/etc that are + copied to /etc in case those files are missing there. Unfortunately + the content does not match the openSUSE defaults. + +------------------------------------------------------------------- +Mon Apr 27 14:33:35 UTC 2020 - Franck Bui + +- Drop most of the tmpfiles that deal with generic paths (bsc#1078466) + + They are problematic because some of them conflict with SUSE + defaults. Therefore it seems better to let the revelant packages + owning these paths to provide their own definitions instead. + ------------------------------------------------------------------- Fri Apr 24 07:38:48 UTC 2020 - Franck Bui diff --git a/systemd-mini.spec b/systemd-mini.spec index c34ec20d..5644b36f 100644 --- a/systemd-mini.spec +++ b/systemd-mini.spec @@ -151,6 +151,7 @@ Source2: systemd-user Source3: systemd-sysv-convert Source4: systemd-sysv-install %endif +Source5: tmpfiles-suse.conf Source6: baselibs.conf Source11: after-local.service Source14: kbd-model-map.legacy @@ -165,9 +166,7 @@ Source102: scripts-systemd-migrate-sysconfig-i18n.sh # broken in upstream and need an urgent fix. Even in this case, the # patches are temporary and should be removed as soon as a fix is # merged by upstream. -Patch1: 0001-SUSE-policy-do-not-clean-tmp-by-default.patch -Patch2: 0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch -Patch3: 0001-Revert-job-Don-t-mark-as-redundant-if-deps-are-relev.patch +Patch1: 0001-Revert-job-Don-t-mark-as-redundant-if-deps-are-relev.patch %description Systemd is a system and service manager, compatible with SysV and LSB @@ -582,12 +581,6 @@ rm %{buildroot}%{_sbindir}/resolvconf rm %{buildroot}%{_mandir}/man1/resolvconf.1* %endif -# FIXME: These obsolete symlinks are still needed by YaST so let's -# keep them until boo#1160890 is fixed. -mkdir -p %{buildroot}/sbin -ln -sf %{_bindir}/udevadm %{buildroot}/sbin/udevadm -ln -sf %{_prefix}/lib/systemd/systemd-udevd %{buildroot}/sbin/udevd - %if %{with sysvcompat} mkdir -p %{buildroot}%{_localstatedir}/lib/systemd/sysv-convert mkdir -p %{buildroot}%{_localstatedir}/lib/systemd/migrated @@ -741,6 +734,35 @@ rm -f %{buildroot}%{_presetdir}/*.preset echo 'disable *' >%{buildroot}%{_presetdir}/99-default.preset echo 'disable *' >%{buildroot}%{_userpresetdir}/99-default.preset +# The tmpfiles dealing with the generic paths is pretty messy +# currently because: +# +# 1. filesystem package wants to define the generic paths and some of +# them conflict with the definition given by systemd in var.conf, +# see bsc#1078466. +# +# 2. /tmp and /var/tmp are not cleaned by default on SUSE distros +# (fate#314974) which conflict with tmp.conf. +# +# 3. There're also legacy.conf which defines various legacy paths +# which either don't match the SUSE defaults or don't look needed +# at all. +# +# 4. And to finish, we don't want the part in etc.conf which imports +# default upstream files in empty /etc, see below. +# +# To keep things simple, we remove all these tmpfiles config files but +# still keep the remaining paths that still don't have a better home +# in suse.conf. +rm -f %{buildroot}%{_tmpfilesdir}/{etc,home,legacy,tmp,var}.conf +install -m 644 %{S:5} %{buildroot}%{_tmpfilesdir}/suse.conf + +# The content of the files shipped by systemd doesn't match the +# defaults used by SUSE. Don't ship those files but leave the decision +# to use the mechanism to the individual packages that actually +# consume those configs (like glibc or pam), see bsc#1170146. +rm -fr %{buildroot}%{_datadir}/factory/* + # Add entries for xkeyboard-config converted keymaps; mappings, which # already exist in original systemd mapping table are being ignored # though, i.e. not overwritten; needed as long as YaST uses console @@ -1353,8 +1375,6 @@ fi %files -n udev%{?mini} %defattr(-,root,root) -/sbin/udevd -/sbin/udevadm %{_bindir}/udevadm %{_bindir}/systemd-hwdb %dir %{_prefix}/lib/udev/ diff --git a/systemd.changes b/systemd.changes index ad86ea9d..fa100f54 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,28 @@ +------------------------------------------------------------------- +Mon Apr 27 15:45:50 UTC 2020 - Franck Bui + +- Drop legacy /sbin/{udevd,udevadm) symlinks hopefully for good + + Since boo#1160890 has been fixed since a couple of months now. + +------------------------------------------------------------------- +Mon Apr 27 14:50:36 UTC 2020 - Franck Bui + +- Drop content of /usr/share/factory/ (bsc#1170146) + + systemd ships several files in /usr/share/factory/etc that are + copied to /etc in case those files are missing there. Unfortunately + the content does not match the openSUSE defaults. + +------------------------------------------------------------------- +Mon Apr 27 14:33:35 UTC 2020 - Franck Bui + +- Drop most of the tmpfiles that deal with generic paths (bsc#1078466) + + They are problematic because some of them conflict with SUSE + defaults. Therefore it seems better to let the revelant packages + owning these paths to provide their own definitions instead. + ------------------------------------------------------------------- Fri Apr 24 07:38:48 UTC 2020 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 917aee96..efefdb63 100644 --- a/systemd.spec +++ b/systemd.spec @@ -149,6 +149,7 @@ Source2: systemd-user Source3: systemd-sysv-convert Source4: systemd-sysv-install %endif +Source5: tmpfiles-suse.conf Source6: baselibs.conf Source11: after-local.service Source14: kbd-model-map.legacy @@ -163,9 +164,7 @@ Source102: scripts-systemd-migrate-sysconfig-i18n.sh # broken in upstream and need an urgent fix. Even in this case, the # patches are temporary and should be removed as soon as a fix is # merged by upstream. -Patch1: 0001-SUSE-policy-do-not-clean-tmp-by-default.patch -Patch2: 0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch -Patch3: 0001-Revert-job-Don-t-mark-as-redundant-if-deps-are-relev.patch +Patch1: 0001-Revert-job-Don-t-mark-as-redundant-if-deps-are-relev.patch %description Systemd is a system and service manager, compatible with SysV and LSB @@ -580,12 +579,6 @@ rm %{buildroot}%{_sbindir}/resolvconf rm %{buildroot}%{_mandir}/man1/resolvconf.1* %endif -# FIXME: These obsolete symlinks are still needed by YaST so let's -# keep them until boo#1160890 is fixed. -mkdir -p %{buildroot}/sbin -ln -sf %{_bindir}/udevadm %{buildroot}/sbin/udevadm -ln -sf %{_prefix}/lib/systemd/systemd-udevd %{buildroot}/sbin/udevd - %if %{with sysvcompat} mkdir -p %{buildroot}%{_localstatedir}/lib/systemd/sysv-convert mkdir -p %{buildroot}%{_localstatedir}/lib/systemd/migrated @@ -739,6 +732,35 @@ rm -f %{buildroot}%{_presetdir}/*.preset echo 'disable *' >%{buildroot}%{_presetdir}/99-default.preset echo 'disable *' >%{buildroot}%{_userpresetdir}/99-default.preset +# The tmpfiles dealing with the generic paths is pretty messy +# currently because: +# +# 1. filesystem package wants to define the generic paths and some of +# them conflict with the definition given by systemd in var.conf, +# see bsc#1078466. +# +# 2. /tmp and /var/tmp are not cleaned by default on SUSE distros +# (fate#314974) which conflict with tmp.conf. +# +# 3. There're also legacy.conf which defines various legacy paths +# which either don't match the SUSE defaults or don't look needed +# at all. +# +# 4. And to finish, we don't want the part in etc.conf which imports +# default upstream files in empty /etc, see below. +# +# To keep things simple, we remove all these tmpfiles config files but +# still keep the remaining paths that still don't have a better home +# in suse.conf. +rm -f %{buildroot}%{_tmpfilesdir}/{etc,home,legacy,tmp,var}.conf +install -m 644 %{S:5} %{buildroot}%{_tmpfilesdir}/suse.conf + +# The content of the files shipped by systemd doesn't match the +# defaults used by SUSE. Don't ship those files but leave the decision +# to use the mechanism to the individual packages that actually +# consume those configs (like glibc or pam), see bsc#1170146. +rm -fr %{buildroot}%{_datadir}/factory/* + # Add entries for xkeyboard-config converted keymaps; mappings, which # already exist in original systemd mapping table are being ignored # though, i.e. not overwritten; needed as long as YaST uses console @@ -1351,8 +1373,6 @@ fi %files -n udev%{?mini} %defattr(-,root,root) -/sbin/udevd -/sbin/udevadm %{_bindir}/udevadm %{_bindir}/systemd-hwdb %dir %{_prefix}/lib/udev/ diff --git a/tmpfiles-suse.conf b/tmpfiles-suse.conf new file mode 100644 index 00000000..885e852c --- /dev/null +++ b/tmpfiles-suse.conf @@ -0,0 +1,15 @@ +# +# See tmpfiles.d(5) for details +# +# Type Path Mode User Group Age Argument + +# Legacy symlink. Maybe should be owned by util-linux ? +L+ /etc/mtab - - - - ../proc/self/mounts + +# FIXME: Might be moved to lockded. +d /run/lock 0775 root lock - + +# FIXME: Should these one be moved to shadow ? +f /var/log/wtmp 0664 root utmp - +f /var/log/btmp 0660 root utmp - +f /var/log/lastlog 0664 root utmp - From 3ab3f4e8263521d90c9679d5f0d7249c4570651d896cca0c927b138b29f4c2f2 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Tue, 28 Apr 2020 08:16:13 +0000 Subject: [PATCH 2/2] Accepting request 798571 from home:fbui:systemd:openSUSE-Factory Mention 2 dropped patches in .changes OBS-URL: https://build.opensuse.org/request/show/798571 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1098 --- systemd-mini.changes | 6 ++++++ systemd.changes | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/systemd-mini.changes b/systemd-mini.changes index fa100f54..2f5136ec 100644 --- a/systemd-mini.changes +++ b/systemd-mini.changes @@ -23,6 +23,12 @@ Mon Apr 27 14:33:35 UTC 2020 - Franck Bui defaults. Therefore it seems better to let the revelant packages owning these paths to provide their own definitions instead. + Meanwhile we still keep the homeless definitions in suse.conf until + a better place is found for them. + + Drop 0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch + Drop 0001-SUSE-policy-do-not-clean-tmp-by-default.patch + ------------------------------------------------------------------- Fri Apr 24 07:38:48 UTC 2020 - Franck Bui diff --git a/systemd.changes b/systemd.changes index fa100f54..2f5136ec 100644 --- a/systemd.changes +++ b/systemd.changes @@ -23,6 +23,12 @@ Mon Apr 27 14:33:35 UTC 2020 - Franck Bui defaults. Therefore it seems better to let the revelant packages owning these paths to provide their own definitions instead. + Meanwhile we still keep the homeless definitions in suse.conf until + a better place is found for them. + + Drop 0001-Fix-run-lock-group-to-follow-openSUSE-policy.patch + Drop 0001-SUSE-policy-do-not-clean-tmp-by-default.patch + ------------------------------------------------------------------- Fri Apr 24 07:38:48 UTC 2020 - Franck Bui