summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.in48
1 files changed, 37 insertions, 11 deletions
diff --git a/Makefile.in b/Makefile.in
index 61a4f04..a4b6be7 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -20,6 +20,7 @@
package_name = @package_name@
package_version = @package_version@
package_description = @package_description@
+package_library = @package_library@
srcdir = @srcdir@
prefix = @prefix@
@@ -206,17 +207,42 @@ install-locale:
chmod 644 "$${df}"; \
done
-uninstall:
- @printf 'Uninstalling executable files...\n'
- @cd src && $(MAKE) $(MACROS) uninstall
- @printf 'Uninstalling library files...\n'
- @cd lib/package && $(MAKE) $(MACROS) uninstall
- @cd lib/metadata && $(MAKE) $(MACROS) uninstall
- @cd lib && $(MAKE) $(MACROS) uninstall
- @printf 'Uninstalling locales...\n'
- @cd locale && $(MAKE) $(MACROS) uninstall
- @printf 'Uninstalling manual pages...\n'
- @cd man && $(MAKE) $(MACROS) uninstall
+uninstall_cmds = \
+ set -e; \
+ for f in $${files}; do \
+ printf ' RM %s\n' "$${f}"; \
+ ff="$$(basename "$${f}")"; \
+ rm -f "$(DESTDIR)/$${dir}/$${ff}"; \
+ done
+uninstall: uninstall-exec uninstall-data
+uninstall-exec: uninstall-bin uninstall-pkglibpackage uninstall-pkglibmetadata \
+ uninstall-pkglib
+uninstall-bin:
+ @files='$(bin)'; dir='$(bindir)'; $(uninstall_cmds)
+uninstall-pkglib:
+ @files='$(pkglib)'; dir='$(pkglibdir)'; $(uninstall_cmds)
+ @rmdir '$(DESTDIR)/$(pkglibdir)'
+uninstall-pkglibpackage:
+ @files='$(pkglibpackage)'; dir='$(pkglibpackagedir)'; \
+ $(uninstall_cmds)
+ @rmdir '$(DESTDIR)/$(pkglibpackagedir)'
+uninstall-pkglibmetadata:
+ @files='$(pkglibmetadata)'; dir='$(pkglibmetadatadir)'; \
+ $(uninstall_cmds)
+ @rmdir '$(DESTDIR)/$(pkglibmetadatadir)'
+uninstall-data: uninstall-man1 uninstall-man3 uninstall-locale
+uninstall-man1:
+ @files='$(man1)'; dir='$(man1dir)'; $(uninstall_cmds)
+uninstall-man3:
+ @files='$(man3)'; dir='$(man3dir)'; $(uninstall_cmds)
+uninstall-locale:
+ @set -e; for f in $(locale); do \
+ printf ' RM %s\n' "$${f}"; \
+ ff="$${f#*/}"; \
+ dd="$(DESTDIR)/$(localedir)/$${ff%/?*}/LC_MESSAGES"; \
+ df="$${dd}/$${ff##*/}"; \
+ rm -f "$${df}"; \
+ done
test: all
@printf 'Running tests...\n'