diff --git a/alsa-utils.changes b/alsa-utils.changes index b7ef0fb..57c2493 100644 --- a/alsa-utils.changes +++ b/alsa-utils.changes @@ -2,6 +2,8 @@ Sun Oct 18 19:12:43 CEST 2020 - tiwai@suse.de - Use /run/lock for alsactl lock directory (bsc#1177826) +- Migrate the old asound.state file if the new path isn't present + yet (bsc#1177826) ------------------------------------------------------------------- Mon Oct 5 12:39:42 CEST 2020 - tiwai@suse.de diff --git a/alsa-utils.spec b/alsa-utils.spec index 6ee6afd..dabdf19 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -116,6 +116,11 @@ install -c -m 0755 %{SOURCE5} %{buildroot}%{_prefix}/lib/systemd/scripts %post %service_add_post sound-extra.service +# migrate the old asound.state +test -f %{_localstatedir}/lib/alsa/asound.state || \ + test -f /etc/asound.state && \ + cp -a /etc/asound.state %{_localstatedir}/lib/alsa/asound.state +exit 0 %preun %service_del_preun sound-extra.service