diff options
Diffstat (limited to 'icons/Makefile.am')
-rw-r--r-- | icons/Makefile.am | 75 |
1 files changed, 22 insertions, 53 deletions
diff --git a/icons/Makefile.am b/icons/Makefile.am index 8c0bb75..74c57b5 100644 --- a/icons/Makefile.am +++ b/icons/Makefile.am @@ -1,64 +1,26 @@ -NULL = -public_icons_themes = \ - hicolor \ - $(NULL) +iconsdir = $(datadir)/icons/hicolor png_icons = \ - hicolor_apps_16x16_mate-desktop.png \ - hicolor_apps_22x22_mate-desktop.png \ - hicolor_apps_24x24_mate-desktop.png \ - hicolor_apps_32x32_mate-desktop.png \ - hicolor_apps_48x48_mate-desktop.png \ - hicolor_apps_128x128_mate-desktop.png \ - $(NULL) - -public_icons = \ + 16x16/apps/mate-desktop.png \ + 22x22/apps/mate-desktop.png \ + 24x24/apps/mate-desktop.png \ + 32x32/apps/mate-desktop.png \ + 48x48/apps/mate-desktop.png \ + 128x128/apps/mate-desktop.png + +nobase_dist_icons_DATA = \ $(png_icons) \ - hicolor_apps_scalable_mate-desktop.svg \ - hicolor_apps_scalable_mate-desktop-symbolic.svg \ - $(NULL) - -hicolor_apps_%.png: hicolor_apps_scalable_mate-desktop.svg - $(RSVG_CONVERT) \ - -w $(word 1, $(subst x, ,$(word 1,$(subst _, ,$*)))) \ - -h $(word 2, $(subst x, ,$(word 1,$(subst _, ,$*)))) \ - $^ -o $@ - -EXTRA_DIST = \ - $(public_icons) \ - $(NULL) - -############################################################################### - -install-icons: $(public_icons) - for icon in $(public_icons); do \ - THEME=`echo $$icon | cut -d_ -f1`; \ - CONTEXT=`echo $$icon | cut -d_ -f2`; \ - SIZE=`echo $$icon | cut -d_ -f3`; \ - ICONFILE=`echo $$icon | cut -d_ -f4`; \ - mkdir -p $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT; \ - $(INSTALL_DATA) $(srcdir)/$$icon $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT/$$ICONFILE; \ - done - -uninstall-icons: - -for icon in $(public_icons); do \ - THEME=`echo $$icon | cut -d_ -f1`; \ - CONTEXT=`echo $$icon | cut -d_ -f2`; \ - SIZE=`echo $$icon | cut -d_ -f3`; \ - ICONFILE=`echo $$icon | cut -d_ -f4`; \ - rm -f $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT/$$ICONFILE; \ - done - -install-data-local: install-icons - -uninstall-local: uninstall-icons + scalable/apps/mate-desktop.svg \ + scalable/apps/mate-desktop-symbolic.svg gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons/hicolor +.PHONY: build-png-icons clean-png-icons + install-data-hook: update-icon-cache uninstall-hook: update-icon-cache -update-icon-cache: $(public_icons) +update-icon-cache: @-if test -z "$(DESTDIR)"; then \ echo "Updating Gtk icon cache."; \ $(gtk_update_icon_cache); \ @@ -67,6 +29,13 @@ update-icon-cache: $(public_icons) echo "*** $(gtk_update_icon_cache)"; \ fi -.PHONY: clean-png-icons +build-png-icons: + $(RSVG_CONVERT) -w 16 -h 16 scalable/apps/mate-desktop.svg -o 16x16/apps/mate-desktop.png + $(RSVG_CONVERT) -w 22 -h 22 scalable/apps/mate-desktop.svg -o 22x22/apps/mate-desktop.png + $(RSVG_CONVERT) -w 24 -h 24 scalable/apps/mate-desktop.svg -o 24x24/apps/mate-desktop.png + $(RSVG_CONVERT) -w 32 -h 32 scalable/apps/mate-desktop.svg -o 32x32/apps/mate-desktop.png + $(RSVG_CONVERT) -w 48 -h 48 scalable/apps/mate-desktop.svg -o 48x48/apps/mate-desktop.png + $(RSVG_CONVERT) -w 128 -h 128 scalable/apps/mate-desktop.svg -o 128x128/apps/mate-desktop.png + clean-png-icons: rm -f $(png_icons) |