summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2010-09-01 17:04:32 +0200
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2010-09-12 19:24:58 +0200
commit50f8b80f2abf4e7fd0572500af064cb5ce25fba6 (patch)
treeccf5ad09a573151148c362656c65935e1cdc6c4b
parent33070528796dafe90ebab836356fea03f2dc24f9 (diff)
downloadbuildroot-novena-50f8b80f2abf4e7fd0572500af064cb5ce25fba6.tar.gz
buildroot-novena-50f8b80f2abf4e7fd0572500af064cb5ce25fba6.zip
bind: remove old-style hook usage and step override
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-rw-r--r--package/bind/bind.mk23
1 files changed, 14 insertions, 9 deletions
diff --git a/package/bind/bind.mk b/package/bind/bind.mk
index e57f26707..8e4867a50 100644
--- a/package/bind/bind.mk
+++ b/package/bind/bind.mk
@@ -27,21 +27,26 @@ BIND_CONF_OPT = \
--disable-epoll \
--disable-threads
-$(eval $(call AUTOTARGETS,package,bind))
-
-$(BIND_HOOK_POST_INSTALL):
+define BIND_TARGET_INSTALL_FIXES
rm -f $(TARGET_DIR)/usr/bin/isc-config.sh
-ifneq ($(BR2_PACKAGE_BIND_TOOLS),y)
+ $(INSTALL) -m 0755 -D package/bind/bind.sysvinit $(TARGET_DIR)/etc/init.d/S81named
+endef
+
+BIND_POST_INSTALL_TARGET_HOOKS += BIND_TARGET_INSTALL_FIXES
+
+define BIND_TARGET_REMOVE_TOOLS
rm -rf $(addprefix $(TARGET_DIR)/usr/bin/, $(BIND_TARGET_BINS))
+endef
+
+ifneq ($(BR2_PACKAGE_BIND_TOOLS),y)
+BIND_POST_INSTALL_TARGET_HOOKS += BIND_TARGET_REMOVE_TOOLS
endif
- $(INSTALL) -m 0755 -D package/bind/bind.sysvinit $(TARGET_DIR)/etc/init.d/S81named
- touch $@
-$(BIND_TARGET_UNINSTALL):
- $(call MESSAGE,"Uninstalling")
+define BIND_UNINSTALL_TARGET_CMDS
rm -rf $(addprefix $(TARGET_DIR)/usr/sbin/, $(BIND_TARGET_SBINS))
rm -rf $(addprefix $(TARGET_DIR)/usr/bin/, $(BIND_TARGET_BINS))
rm -rf $(addprefix $(TARGET_DIR)/usr/lib/, $(BIND_TARGET_LIBS))
rm -f $(TARGET_DIR)/etc/init.d/S81named
- rm -f $(BIND_TARGET_INSTALL_TARGET) $(BIND_HOOK_POST_INSTALL)
+endef
+$(eval $(call AUTOTARGETS,package,bind))