summaryrefslogtreecommitdiff
path: root/package/usbutils
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2010-09-16 13:25:32 +0200
committerPeter Korsgaard <jacmet@sunsite.dk>2010-09-16 13:36:00 +0200
commit1860bdae8cdf4f9eb7097fd7e5ed7e9c0c5b6a75 (patch)
treeb3b4fb6139799602676e100126c19055b18ac7f0 /package/usbutils
parentc106fdbd100f36fe3329360af8f656566937f00a (diff)
parentae2be8dbc36293d8243baf2b13ad17a47738d6d3 (diff)
Merge branch 'for-2010.11/remove-oldstyle-hooks' of git://git.busybox.net/~tpetazzoni/git/buildroot
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/usbutils')
-rw-r--r--package/usbutils/usbutils.mk30
1 files changed, 23 insertions, 7 deletions
diff --git a/package/usbutils/usbutils.mk b/package/usbutils/usbutils.mk
index 0f821281e..508ca0d3a 100644
--- a/package/usbutils/usbutils.mk
+++ b/package/usbutils/usbutils.mk
@@ -14,18 +14,34 @@ else
USBUTILS_CONF_OPT = --disable-zlib
endif
-$(eval $(call AUTOTARGETS,package,usbutils))
-
-$(USBUTILS_HOOK_POST_INSTALL):
+define USBUTILS_TARGET_CLEANUP
rm -f $(TARGET_DIR)/usr/bin/usb-devices
rm -f $(TARGET_DIR)/usr/sbin/update-usbids.sh
rm -f $(TARGET_DIR)/usr/share/pkgconfig/usbutils.pc
-ifeq ($(BR2_PACKAGE_USBUTILS_ZLIB),y)
+endef
+
+USBUTILS_POST_INSTALL_TARGET_HOOKS += USBUTILS_TARGET_CLEANUP
+
+define USBUTILS_REMOVE_UNCOMPRESSED_IDS
rm -f $(TARGET_DIR)/usr/share/usb.ids
-else
+endef
+
+define USBUTILS_REMOVE_COMPRESSED_IDS
rm -f $(TARGET_DIR)/usr/share/usb.ids.gz
+endef
+
+ifeq ($(BR2_PACKAGE_USBUTILS_ZLIB),y)
+USBUTILS_POST_INSTALL_TARGET_HOOKS += USBUTILS_REMOVE_UNCOMPRESSED_IDS
+else
+USBUTILS_POST_INSTALL_TARGET_HOOKS += USBUTILS_REMOVE_COMPRESSED_IDS
endif
-ifneq ($(BR2_HAVE_DEVFILES),y)
+
+define USBUTILS_REMOVE_DEVFILES
rm -f $(TARGET_DIR)/usr/bin/libusb-config
+endef
+
+ifneq ($(BR2_HAVE_DEVFILES),y)
+USBUTILS_POST_INSTALL_TARGET_HOOKS += USBUTILS_REMOVE_DEVFILES
endif
- touch $@
+
+$(eval $(call AUTOTARGETS,package,usbutils))