2006-06-23 08:52:33 +02:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# hdparm
|
|
|
|
#
|
|
|
|
#############################################################
|
2007-09-24 11:00:39 +02:00
|
|
|
HDPARM_VERSION:=7.7
|
2006-11-17 17:01:05 +01:00
|
|
|
HDPARM_SOURCE:=hdparm-$(HDPARM_VERSION).tar.gz
|
2007-09-24 11:00:39 +02:00
|
|
|
HDPARM_SITE:=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/hdparm
|
2006-10-01 17:17:52 +02:00
|
|
|
HDPARM_CAT:=$(ZCAT)
|
2006-11-17 17:01:05 +01:00
|
|
|
HDPARM_DIR:=$(BUILD_DIR)/hdparm-$(HDPARM_VERSION)
|
2006-06-23 08:52:33 +02:00
|
|
|
HDPARM_BINARY:=hdparm
|
|
|
|
HDPARM_TARGET_BINARY:=sbin/hdparm
|
|
|
|
|
|
|
|
$(DL_DIR)/$(HDPARM_SOURCE):
|
2009-01-16 12:42:52 +01:00
|
|
|
$(call DOWNLOAD,$(HDPARM_SITE),$(HDPARM_SOURCE))
|
2006-06-23 08:52:33 +02:00
|
|
|
|
|
|
|
hdparm-source: $(DL_DIR)/$(HDPARM_SOURCE)
|
|
|
|
|
|
|
|
$(HDPARM_DIR)/.unpacked: $(DL_DIR)/$(HDPARM_SOURCE)
|
|
|
|
$(HDPARM_CAT) $(DL_DIR)/$(HDPARM_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
|
2007-09-24 11:00:39 +02:00
|
|
|
toolchain/patch-kernel.sh $(HDPARM_DIR) package/hdparm \*.patch
|
|
|
|
touch $@
|
2006-06-23 08:52:33 +02:00
|
|
|
|
2007-09-24 11:00:39 +02:00
|
|
|
$(HDPARM_DIR)/$(HDPARM_BINARY): $(HDPARM_DIR)/.unpacked
|
|
|
|
$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(HDPARM_DIR) \
|
|
|
|
CFLAGS="$(TARGET_CFLAGS)" \
|
|
|
|
LDFLAGS="$(TARGET_LDFLAGS)"
|
2006-06-23 08:52:33 +02:00
|
|
|
|
|
|
|
$(TARGET_DIR)/$(HDPARM_TARGET_BINARY): $(HDPARM_DIR)/$(HDPARM_BINARY)
|
2007-07-20 16:37:48 +02:00
|
|
|
rm -f $(TARGET_DIR)/$(HDPARM_TARGET_BINARY)
|
2007-09-24 11:00:39 +02:00
|
|
|
$(INSTALL) -D -m 0755 $(HDPARM_DIR)/$(HDPARM_BINARY) $(TARGET_DIR)/$(HDPARM_TARGET_BINARY)
|
|
|
|
ifeq ($(BR2_HAVE_MANPAGES),y)
|
|
|
|
$(INSTALL) -D $(HDPARM_DIR)/hdparm.8 $(TARGET_DIR)/usr/share/man/man8/hdparm.8
|
|
|
|
endif
|
2007-10-01 18:15:31 +02:00
|
|
|
$(STRIPCMD) $(STRIP_STRIP_ALL) $@
|
2006-06-23 08:52:33 +02:00
|
|
|
|
2009-09-02 17:02:02 +02:00
|
|
|
hdparm: $(TARGET_DIR)/$(HDPARM_TARGET_BINARY)
|
2006-06-23 08:52:33 +02:00
|
|
|
|
|
|
|
hdparm-clean:
|
|
|
|
-$(MAKE) -C $(HDPARM_DIR) clean
|
2007-09-24 11:00:39 +02:00
|
|
|
rm -f $(TARGET_DIR)/$(HDPARM_TARGET_BINARY)
|
2006-06-23 08:52:33 +02:00
|
|
|
|
|
|
|
hdparm-dirclean:
|
|
|
|
rm -rf $(HDPARM_DIR)
|
|
|
|
|
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# Toplevel Makefile options
|
|
|
|
#
|
|
|
|
#############################################################
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_HDPARM),y)
|
2006-06-23 08:52:33 +02:00
|
|
|
TARGETS+=hdparm
|
|
|
|
endif
|