From 6cfff7672621c7516fd04ae7f1dbe4801193c59f Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Thu, 10 Jul 2008 09:49:24 +0000 Subject: 1.83: intelligent %update_icon_cache/%clean_icon_cache which are null for caches handled through filetriggers, but as used to be for other caches --- build.macros.in | 17 +++++++++++++++-- configure.ac | 2 +- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/build.macros.in b/build.macros.in index 6d7d2c3..be64ef2 100644 --- a/build.macros.in +++ b/build.macros.in @@ -86,8 +86,6 @@ Group: %{group}\ %clean_desktop_database %{nil} %update_mime_database %{nil} %clean_mime_database %{nil} -%update_icon_cache() %{nil} -%clean_icon_cache() %{nil} %update_scrollkeeper %{nil} %clean_scrollkeeper %{nil} @@ -106,6 +104,21 @@ Group: %{group}\ %clean_gcjdb if [ -x %{_rebuildgcjdb_bin} ]; then %{_rebuildgcjdb_bin} || true ; fi \ %{nil} +# Rebuild icon cache +# +# following themes are handled through filetriggers: +%define icon_cache_through_filetrigger_hicolor 1 +%define icon_cache_through_filetrigger_gnome 1 +%define icon_cache_through_filetrigger_oxygen 1 + +%define update_icon_cache() %{expand: %%{!?icon_cache_through_filetrigger_%1:if [ -x %%{_update_icon_cache_bin} ]; then \ +%%{_update_icon_cache_bin} --force --quiet %%{_iconsdir}/%%{1} || true; fi \ +%%{nil}}} + +%define clean_icon_cache() %{expand: %%{!?icon_cache_through_filetrigger_%1:if [ -x %%{_update_icon_cache_bin} -a -r %%{_iconsdir}/%%{1}/index.theme ]; then \ +%%{_update_icon_cache_bin} --force --quiet %%{_iconsdir}/%%{1} || true ; fi \ +%%{nil}}} + # GConf schemas: # installation is handled by filetriggers %post_install_gconf_schemas() %{nil} diff --git a/configure.ac b/configure.ac index ab6548a..656843d 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,7 @@ # $Id$ AC_PREREQ(2.59) -AC_INIT(rpm-mandriva-setup, 1.82, nanardon@mandriva.org) +AC_INIT(rpm-mandriva-setup, 1.83, nanardon@mandriva.org) AC_CANONICAL_TARGET AM_INIT_AUTOMAKE(1.9) AC_CONFIG_SRCDIR -- cgit v1.2.1