call update-icon-cache (please test yourself)
authorJoachim Breitner <mail@joachim-breitner.de>
Thu, 20 Mar 2008 11:49:34 +0000 (11:49 +0000)
committerJoachim Breitner <mail@joachim-breitner.de>
Thu, 20 Mar 2008 11:49:34 +0000 (11:49 +0000)
Makefile.am

index 48d2a9e..c13b762 100644 (file)
@@ -7,5 +7,19 @@ sm_LDADD = $(DEPS_LIBS)
 icondir = $(datadir)/icons/hicolor/48x48/apps
 icon_DATA = sm.png
 
+gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons/hicolor
+
+install-data-hook: update-icon-cache
+uninstall-hook: update-icon-cache
+update-icon-cache:
+       @-if test -z "$(DESTDIR)"; then \
+               echo "Updating Gtk icon cache."; \
+               $(gtk_update_icon_cache); \
+       else \
+               echo "*** Icon cache not updated.  After (un)install, run this:"; \
+               echo "***   $(gtk_update_icon_cache)"; \
+       fi
+
+
 man_MANS = sm.1
 EXTRA_DIST = sm.1 sm.py sm.png