From 8869f7ec2a15bbf9f723be08f7af34aaaa6788615b331eff4e5058ec962af986 Mon Sep 17 00:00:00 2001 From: Frank Sundermeyer Date: Tue, 20 Mar 2012 14:36:14 +0000 Subject: [PATCH] * Bugfix: fixed %postun routine, so catalog entries only get removed on a real package installation OBS-URL: https://build.opensuse.org/package/show/Documentation:Tools/suse-xsl-stylesheets?expand=0&rev=18 --- suse-xsl-stylesheets-1.9.1.tar.bz2 | 4 ++-- suse-xsl-stylesheets.changes | 6 ++++++ suse-xsl-stylesheets.spec | 12 +++++++++--- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/suse-xsl-stylesheets-1.9.1.tar.bz2 b/suse-xsl-stylesheets-1.9.1.tar.bz2 index d2be434..0dd4998 100644 --- a/suse-xsl-stylesheets-1.9.1.tar.bz2 +++ b/suse-xsl-stylesheets-1.9.1.tar.bz2 @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d80e66d2f4c74422982fb125ce28be90f75eb4b50d8b4353aed1b96dcdb1b707 -size 748832 +oid sha256:2471b6377f4f88735bb153b158a0e804f5f95c246a5302f24e451945dea9c052 +size 735144 diff --git a/suse-xsl-stylesheets.changes b/suse-xsl-stylesheets.changes index b4af43d..88ff187 100644 --- a/suse-xsl-stylesheets.changes +++ b/suse-xsl-stylesheets.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Mar 20 14:34:57 UTC 2012 - fsundermeyer@opensuse.org + +* Bugfix: fixed %postun routine, so catalog entries only get removed + on a real package installation + ------------------------------------------------------------------- Tue Mar 20 09:26:57 UTC 2012 - toms@opensuse.org diff --git a/suse-xsl-stylesheets.spec b/suse-xsl-stylesheets.spec index 0e41526..4c165f1 100644 --- a/suse-xsl-stylesheets.spec +++ b/suse-xsl-stylesheets.spec @@ -120,8 +120,13 @@ exit 0 # # Remove catalog entries # -if [ ! -f %{_sysconfdir}/xml/%{novdoc_catalog} -a -x /usr/bin/edit-xml-catalog ] ; then - # SGML +# delete catalog entries +# only run if package is really uninstalled ($1 = 0) and not +# in case of an update +# +if [ 0 = $1 ]; then + if [ ! -f %{_sysconfdir}/xml/%{novdoc_catalog} -a -x /usr/bin/edit-xml-catalog ] ; then + # SGML for c in catalog/CATALOG.%{dtdname}-%{dtdversion}; do %{regcat} -r %{_datadir}/sgml/$c >/dev/null 2>&1 done @@ -132,7 +137,8 @@ if [ ! -f %{_sysconfdir}/xml/%{novdoc_catalog} -a -x /usr/bin/edit-xml-catalog ] # susexsl entry edit-xml-catalog --group --catalog /etc/xml/suse-catalog.xml \ --del %{name} -fi + fi +} exit 0