summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2011-01-31 19:02:36 (GMT)
committer Peter Korsgaard <jacmet@sunsite.dk>2011-01-31 19:02:36 (GMT)
commit7e7a8dc85e92171e93e14eb0323bc518ecada3cc (patch)
tree40a447d18c596ed61dd768cd3b56b27040f6e210
parent5bc9f45dfbfa39e80622e9b482ce3a96b57d839a (diff)
downloadbuildroot-7e7a8dc85e92171e93e14eb0323bc518ecada3cc.tar.gz
buildroot-7e7a8dc85e92171e93e14eb0323bc518ecada3cc.tar.bz2
libusb-compat: fixup libusb-config script similarly to other *-config scripts
So programs using this don't end up looking for host includes / libraries. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
-rw-r--r--package/libusb-compat/libusb-compat.mk8
1 files changed, 8 insertions, 0 deletions
diff --git a/package/libusb-compat/libusb-compat.mk b/package/libusb-compat/libusb-compat.mk
index 98271c7..6590e89 100644
--- a/package/libusb-compat/libusb-compat.mk
+++ b/package/libusb-compat/libusb-compat.mk
@@ -11,4 +11,12 @@ LIBUSB_COMPAT_DEPENDENCIES = host-pkg-config libusb
LIBUSB_COMPAT_INSTALL_STAGING = YES
LIBUSB_COMPAT_INSTALL_TARGET = YES
+define LIBUSB_COMPAT_FIXUP_CONFIG
+ $(SED) 's%prefix=/usr%prefix=$(STAGING_DIR)/usr%' \
+ -e 's%exec_prefix=/usr%exec_prefix=$(STAGING_DIR)/usr%' \
+ $(STAGING_DIR)/usr/bin/libusb-config
+endef
+
+LIBUSB_COMPAT_POST_INSTALL_STAGING_HOOKS+=LIBUSB_COMPAT_FIXUP_CONFIG
+
$(eval $(call AUTOTARGETS,package,libusb-compat))