From cb5a5701e186ac3f1f3ed978f69f10410548a24ff8ff5a38712c5e33cf1cba9a Mon Sep 17 00:00:00 2001 From: Clemens Famulla-Conrad Date: Tue, 6 Sep 2022 08:30:42 +0000 Subject: [PATCH] Accepting request 1000701 from home:schubi2 Migration to /usr/etc: Saving user changed configuration files in /etc and restoring them while an RPM update. OBS-URL: https://build.opensuse.org/request/show/1000701 OBS-URL: https://build.opensuse.org/package/show/hardware/wpa_supplicant?expand=0&rev=139 --- wpa_supplicant.changes | 11 +++++++++++ wpa_supplicant.spec | 14 ++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/wpa_supplicant.changes b/wpa_supplicant.changes index e198581..50eaae3 100644 --- a/wpa_supplicant.changes +++ b/wpa_supplicant.changes @@ -1,9 +1,20 @@ +------------------------------------------------------------------- +Thu Sep 1 13:52:19 UTC 2022 - Stefan Schubert + +- Migration to /usr/etc: Saving user changed configuration files + in /etc and restoring them while an RPM update. + ------------------------------------------------------------------- Tue Jul 5 11:29:50 UTC 2022 - Clemens Famulla-Conrad - Add dbus-Fix-property-DebugShowKeys-and-DebugTimestamp.patch (bsc#1201219) +------------------------------------------------------------------- +Tue Jun 21 10:11:36 UTC 2022 - Stefan Schubert + +- Removed %config flag for files in /usr directory. + ------------------------------------------------------------------- Tue Jun 21 07:29:22 UTC 2022 - Stefan Schubert diff --git a/wpa_supplicant.spec b/wpa_supplicant.spec index 5431088..564142b 100644 --- a/wpa_supplicant.spec +++ b/wpa_supplicant.spec @@ -116,6 +116,20 @@ ln -s wpa_supplicant.service %{buildroot}%{_unitdir}/dbus-fi.w1.wpa_supplicant1. %pre %service_add_pre wpa_supplicant.service +%if 0%{?suse_version} > 1500 +# Prepare for migration to /usr/etc; save any old .rpmsave +for i in logrotate.d/wpa_supplicant ; do + test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i}.rpmsave.old ||: +done +%endif + +%if 0%{?suse_version} > 1500 +%posttrans +# Migration to /usr/etc, restore just created .rpmsave +for i in logrotate.d/wpa_supplicant ; do + test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i} ||: +done +%endif %post %service_add_post wpa_supplicant.service