From 9f4748001940009db8589cb3fb4f07764503964d Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Thu, 31 May 2007 15:27:05 +0000 Subject: [PATCH] Cleanup, get rid of ETHTOOL_WORKDIR, use $@ --- package/ethtool/ethtool.mk | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/package/ethtool/ethtool.mk b/package/ethtool/ethtool.mk index 38a2aeae36..5214e0e974 100644 --- a/package/ethtool/ethtool.mk +++ b/package/ethtool/ethtool.mk @@ -7,8 +7,7 @@ ETHTOOL_VERSION=3 ETHTOOL_SOURCE=ethtool-$(ETHTOOL_VERSION).tar.gz ETHTOOL_SITE=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/gkernel/ -ETHTOOL_DIR=$(BUILD_DIR)/${shell basename $(ETHTOOL_SOURCE) .tar.gz} -ETHTOOL_WORKDIR=$(BUILD_DIR)/ethtool-$(ETHTOOL_VERSION) +ETHTOOL_DIR=$(BUILD_DIR)/ethtool-$(ETHTOOL_VERSION) ETHTOOL_CAT:=$(ZCAT) $(DL_DIR)/$(ETHTOOL_SOURCE): @@ -16,7 +15,7 @@ $(DL_DIR)/$(ETHTOOL_SOURCE): $(ETHTOOL_DIR)/.unpacked: $(DL_DIR)/$(ETHTOOL_SOURCE) $(ETHTOOL_CAT) $(DL_DIR)/$(ETHTOOL_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - - touch $(ETHTOOL_DIR)/.unpacked + touch $@ $(ETHTOOL_DIR)/.configured: $(ETHTOOL_DIR)/.unpacked (cd $(ETHTOOL_DIR); rm -rf config.cache; \ @@ -30,26 +29,24 @@ $(ETHTOOL_DIR)/.configured: $(ETHTOOL_DIR)/.unpacked --prefix=/usr \ --sysconfdir=/etc \ ); - touch $(ETHTOOL_DIR)/.configured + touch $@ -$(ETHTOOL_WORKDIR)/ethtool: $(ETHTOOL_DIR)/.configured - $(MAKE) CC=$(TARGET_CC) -C $(ETHTOOL_WORKDIR) +$(ETHTOOL_DIR)/ethtool: $(ETHTOOL_DIR)/.configured + $(MAKE) CC=$(TARGET_CC) -C $(ETHTOOL_DIR) -$(ETHTOOL_WORKDIR)/.installed: $(ETHTOOL_WORKDIR)/ethtool - cp $(ETHTOOL_WORKDIR)/ethtool $(TARGET_DIR)/usr/sbin - touch $(ETHTOOL_WORKDIR)/.installed +$(ETHTOOL_DIR)/.installed: $(ETHTOOL_DIR)/ethtool + cp $(ETHTOOL_DIR)/ethtool $(TARGET_DIR)/usr/sbin + touch $@ -ethtool: uclibc $(ETHTOOL_WORKDIR)/.installed +ethtool: uclibc $(ETHTOOL_DIR)/.installed ethtool-source: $(DL_DIR)/$(ETHTOOL_SOURCE) ethtool-clean: - @if [ -d $(ETHTOOL_WORKDIR)/Makefile ] ; then \ - $(MAKE) -C $(ETHTOOL_WORKDIR) clean ; \ - fi; + -$(MAKE) -C $(ETHTOOL_DIR) clean ethtool-dirclean: - rm -rf $(ETHTOOL_DIR) $(ETHTOOL_WORKDIR) + rm -rf $(ETHTOOL_DIR) ############################################################# # # Toplevel Makefile options -- 2.30.2