From 7889c50c3687f359d94a2a7517e9cdd679090554 Mon Sep 17 00:00:00 2001 From: Christophe CURIS Date: Sun, 9 Jun 2013 13:49:23 +0200 Subject: [PATCH] Configure: Use automake's conditional to handle icon installation The previous method was to use a custom install procedure, which is a bit complex when automake can handle this for us, and as a side effect it made 'distcheck' fail on uninstall procedure check. The new method is to use a simple conditional and autoconf/automake will do all the work for us. Signed-off-by: Christophe CURIS --- WPrefs.app/tiff/Makefile.am | 14 +++----------- WPrefs.app/xpm/Makefile.am | 16 +++------------- configure.ac | 2 ++ 3 files changed, 8 insertions(+), 24 deletions(-) diff --git a/WPrefs.app/tiff/Makefile.am b/WPrefs.app/tiff/Makefile.am index 6927544d..50c75fff 100644 --- a/WPrefs.app/tiff/Makefile.am +++ b/WPrefs.app/tiff/Makefile.am @@ -1,6 +1,7 @@ tiffdatadir = $(wprefs_datadir)/tiff -EXTRA_DIST = \ +if ICON_EXT_TIFF +dist_tiffdata_DATA = \ advancetonewworkspace.tiff \ animations.tiff \ appearance.tiff \ @@ -72,13 +73,4 @@ EXTRA_DIST = \ workspace.tiff \ workspacename.tiff \ xis.tiff - -TIFF_FILES= - -tiffdata_DATA=$(TIFF_FILES) - -install-data-local: - if [ @ICONEXT@ = "tiff" -a x"$(TIFF_FILES)" = "x" ] ; then\ - $(MAKE) install-data TIFF_FILES="$(EXTRA_DIST)";\ - fi - +endif diff --git a/WPrefs.app/xpm/Makefile.am b/WPrefs.app/xpm/Makefile.am index 20b8f9e1..c491a7fc 100644 --- a/WPrefs.app/xpm/Makefile.am +++ b/WPrefs.app/xpm/Makefile.am @@ -1,7 +1,7 @@ xpmdatadir = $(wprefs_datadir)/xpm - -EXTRA_DIST = \ +if ICON_EXT_XPM +dist_xpmdata_DATA = \ advancetonewworkspace.xpm \ animations.xpm \ appearance.xpm \ @@ -72,14 +72,4 @@ EXTRA_DIST = \ workspace.xpm \ workspacename.xpm \ xis.xpm - - -XPM_FILES= - -xpmdata_DATA=$(XPM_FILES) - -install-data-local: - if [ @ICONEXT@ = "xpm" -a x"$(XPM_FILES)" = "x" ] ; then\ - $(MAKE) install-data XPM_FILES="$(EXTRA_DIST)";\ - fi - +endif diff --git a/configure.ac b/configure.ac index 32ea0d68..3feeaaeb 100644 --- a/configure.ac +++ b/configure.ac @@ -792,6 +792,8 @@ AC_SUBST(HEADER_SEARCH_PATH) AC_SUBST(GFXLIBS) AC_SUBST(ICONEXT) +AM_CONDITIONAL([ICON_EXT_XPM], [test "x$ICONEXT" = "xxpm"]) +AM_CONDITIONAL([ICON_EXT_TIFF], [test "x$ICONEXT" = "xtiff"]) dnl ==============================================