From 76d1c729f09db5ecc514ae0520f9a53c353e0401 Mon Sep 17 00:00:00 2001 From: Maxime Hadjinlian Date: Sun, 12 Jul 2015 17:25:57 +0200 Subject: package: Remove shell completion at finalize stage Instead of doing a removal of the completion file package per package, do it all at the finalize stage so it's done once and for all. Note: This fixes an issue with systemd where passing a --bashcompletiondir or --zshcompletiondir would be evaluated to '.' by the autotools macro. This would create a 'target./' directory. Signed-off-by: Maxime Hadjinlian Signed-off-by: Thomas Petazzoni --- Makefile | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 35818f08f..daf692e59 100644 --- a/Makefile +++ b/Makefile @@ -555,6 +555,12 @@ target-finalize: $(PACKAGES) find $(TARGET_DIR)/usr/lib \( -name '*.a' -o -name '*.la' \) -print0 | xargs -0 rm -f ifneq ($(BR2_PACKAGE_GDB),y) rm -rf $(TARGET_DIR)/usr/share/gdb +endif +ifneq ($(BR2_PACKAGE_BASH),y) + rm -rf $(TARGET_DIR)/usr/share/bash-completion +endif +ifneq ($(BR2_PACKAGE_ZSH),y) + rm -rf $(TARGET_DIR)/usr/share/zsh endif rm -rf $(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/man rm -rf $(TARGET_DIR)/usr/info $(TARGET_DIR)/usr/share/info -- cgit v1.2.3