2006-09-28 12:19:43 +02:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# nbd (client only)
|
|
|
|
#
|
|
|
|
#############################################################
|
|
|
|
|
|
|
|
NBD_VERSION=2.8.6
|
|
|
|
NBD_SOURCE=nbd-$(NBD_VERSION).tar.bz2
|
2006-11-17 16:43:51 +01:00
|
|
|
NBD_CAT:=$(BZCAT)
|
2006-09-28 12:19:43 +02:00
|
|
|
NBD_SITE=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/nbd/
|
|
|
|
NBD_DIR=$(BUILD_DIR)/nbd-$(NBD_VERSION)
|
|
|
|
|
|
|
|
$(DL_DIR)/$(NBD_SOURCE):
|
|
|
|
$(WGET) -P $(DL_DIR) $(NBD_SITE)/$(NBD_SOURCE)
|
|
|
|
|
|
|
|
$(NBD_DIR)/.unpacked: $(DL_DIR)/$(NBD_SOURCE)
|
|
|
|
$(NBD_CAT) $(DL_DIR)/$(NBD_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
|
|
|
|
touch $(NBD_DIR)/.unpacked
|
|
|
|
|
|
|
|
$(NBD_DIR)/.configured: $(NBD_DIR)/.unpacked
|
|
|
|
(cd $(NBD_DIR); rm -rf config.cache; \
|
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2007-06-27 14:01:27 +02:00
|
|
|
$(TARGET_CONFIGURE_ARGS) \
|
2006-09-28 12:19:43 +02:00
|
|
|
CC=$(TARGET_CC) \
|
|
|
|
./configure \
|
|
|
|
--target=$(GNU_TARGET_NAME) \
|
|
|
|
--host=$(GNU_TARGET_NAME) \
|
|
|
|
--build=$(GNU_HOST_NAME) \
|
|
|
|
--prefix=/usr \
|
2007-08-21 21:20:18 +02:00
|
|
|
)
|
2006-09-28 12:19:43 +02:00
|
|
|
touch $(NBD_DIR)/.configured
|
|
|
|
|
|
|
|
$(NBD_DIR)/nbd-client: $(NBD_DIR)/.configured
|
|
|
|
$(MAKE) -C $(NBD_DIR) nbd-client
|
|
|
|
|
|
|
|
$(TARGET_DIR)/sbin/nbd-client: $(NBD_DIR)/nbd-client
|
|
|
|
cp $< $@
|
2007-10-01 18:15:31 +02:00
|
|
|
$(STRIPCMD) $@
|
2006-09-28 12:19:43 +02:00
|
|
|
|
2007-08-20 19:21:16 +02:00
|
|
|
nbd: uclibc $(TARGET_DIR)/sbin/nbd-client
|
2006-09-28 12:19:43 +02:00
|
|
|
|
|
|
|
nbd-source: $(DL_DIR)/$(NBD_SOURCE)
|
|
|
|
|
|
|
|
nbd-clean:
|
2008-03-27 16:42:42 +01:00
|
|
|
rm -f $(TARGET_DIR)/sbin/nbd-client
|
|
|
|
-$(MAKE) -C $(NBD_DIR) clean
|
2006-09-28 12:19:43 +02:00
|
|
|
|
|
|
|
nbd-dirclean:
|
|
|
|
rm -rf $(NBD_DIR)
|
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# Toplevel Makefile options
|
|
|
|
#
|
|
|
|
#############################################################
|
|
|
|
ifeq ($(strip $(BR2_PACKAGE_NBD)),y)
|
|
|
|
TARGETS+=nbd
|
|
|
|
endif
|