2004-11-11 15:28:17 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# which
|
|
|
|
#
|
|
|
|
#############################################################
|
2007-07-11 16:06:06 +02:00
|
|
|
WHICH_VERSION:=2.16
|
|
|
|
WHICH_SOURCE:=which-$(WHICH_VERSION).tar.gz
|
2004-11-11 15:28:17 +01:00
|
|
|
WHICH_SITE:=http://www.xs4all.nl/~carlo17/which/
|
2007-07-11 16:06:06 +02:00
|
|
|
WHICH_DIR:=$(BUILD_DIR)/which-$(WHICH_VERSION)
|
2006-10-01 17:17:52 +02:00
|
|
|
WHICH_CAT:=$(ZCAT)
|
2004-11-11 15:28:17 +01:00
|
|
|
WHICH_BINARY:=which
|
|
|
|
WHICH_TARGET_BINARY:=bin/which
|
|
|
|
|
|
|
|
$(DL_DIR)/$(WHICH_SOURCE):
|
|
|
|
$(WGET) -P $(DL_DIR) $(WHICH_SITE)/$(WHICH_SOURCE)
|
|
|
|
|
2007-01-03 14:44:01 +01:00
|
|
|
which-source: $(DL_DIR)/$(WHICH_SOURCE)
|
|
|
|
|
2004-11-11 15:28:17 +01:00
|
|
|
$(WHICH_DIR)/.unpacked: $(DL_DIR)/$(WHICH_SOURCE)
|
|
|
|
$(WHICH_CAT) $(DL_DIR)/$(WHICH_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
|
|
|
|
touch $(WHICH_DIR)/.unpacked
|
|
|
|
|
|
|
|
$(WHICH_DIR)/.configured: $(WHICH_DIR)/.unpacked
|
|
|
|
(cd $(WHICH_DIR); rm -rf config.cache; \
|
2007-01-14 04:52:21 +01:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2007-06-27 14:01:27 +02:00
|
|
|
$(TARGET_CONFIGURE_ARGS) \
|
2004-11-11 15:28:17 +01:00
|
|
|
./configure \
|
|
|
|
--target=$(GNU_TARGET_NAME) \
|
|
|
|
--host=$(GNU_TARGET_NAME) \
|
|
|
|
--build=$(GNU_HOST_NAME) \
|
|
|
|
--prefix=/ \
|
|
|
|
);
|
|
|
|
touch $(WHICH_DIR)/.configured
|
|
|
|
|
|
|
|
$(WHICH_DIR)/$(WHICH_BINARY): $(WHICH_DIR)/.configured
|
|
|
|
$(MAKE) CC=$(TARGET_CC) -C $(WHICH_DIR)
|
|
|
|
|
|
|
|
$(TARGET_DIR)/$(WHICH_TARGET_BINARY): $(WHICH_DIR)/$(WHICH_BINARY)
|
|
|
|
install -D $(WHICH_DIR)/$(WHICH_BINARY) $(TARGET_DIR)/$(WHICH_TARGET_BINARY)
|
|
|
|
|
|
|
|
which: uclibc $(TARGET_DIR)/$(WHICH_TARGET_BINARY)
|
|
|
|
|
|
|
|
which-clean:
|
|
|
|
rm -f $(TARGET_DIR)/$(WHICH_TARGET_BINARY)
|
|
|
|
-$(MAKE) -C $(WHICH_DIR) clean
|
|
|
|
|
|
|
|
which-dirclean:
|
|
|
|
rm -rf $(WHICH_DIR)
|
2005-02-10 04:06:39 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# Toplevel Makefile options
|
|
|
|
#
|
|
|
|
#############################################################
|
|
|
|
ifeq ($(strip $(BR2_PACKAGE_WHICH)),y)
|
|
|
|
TARGETS+=which
|
|
|
|
endif
|