summaryrefslogtreecommitdiffstats
path: root/package/ethtool
diff options
context:
space:
mode:
Diffstat (limited to 'package/ethtool')
-rw-r--r--package/ethtool/ethtool.mk25
1 files changed, 11 insertions, 14 deletions
diff --git a/package/ethtool/ethtool.mk b/package/ethtool/ethtool.mk
index 38a2aeae3..5214e0e97 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