2005-07-21 03:27:08 +03:00
|
|
|
# $Id$
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME := mtd
|
2006-02-09 05:21:01 +02:00
|
|
|
PKG_RELEASE := 4
|
2005-07-21 03:27:08 +03:00
|
|
|
|
|
|
|
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
|
|
|
|
|
|
|
|
include $(TOPDIR)/package/rules.mk
|
|
|
|
|
|
|
|
$(eval $(call PKG_template,MTD,$(PKG_NAME),$(PKG_RELEASE),$(ARCH)))
|
2005-09-14 18:30:53 +03:00
|
|
|
$(eval $(call PKG_template,MTD_STATIC,mtd-static,$(PKG_RELEASE),$(ARCH)))
|
2005-07-21 03:27:08 +03:00
|
|
|
|
|
|
|
$(PKG_BUILD_DIR)/.prepared:
|
2005-11-07 20:12:11 +02:00
|
|
|
mkdir -p $(PKG_BUILD_DIR)
|
|
|
|
touch $@
|
|
|
|
|
|
|
|
$(PKG_BUILD_DIR)/.configured:
|
2005-07-21 03:27:08 +03:00
|
|
|
touch $@
|
|
|
|
|
|
|
|
$(PKG_BUILD_DIR)/.built:
|
2005-09-04 03:13:34 +03:00
|
|
|
$(TARGET_CC) $(TARGET_CFLAGS) -o $(PKG_BUILD_DIR)/mtd mtd.c
|
2005-09-14 18:30:53 +03:00
|
|
|
$(TARGET_CC) -static $(TARGET_CFLAGS) -o $(PKG_BUILD_DIR)/mtd-static mtd.c
|
2005-07-21 03:27:08 +03:00
|
|
|
touch $@
|
|
|
|
|
|
|
|
$(IPKG_MTD):
|
|
|
|
install -d -m0755 $(IDIR_MTD)/sbin
|
|
|
|
install -m0755 $(PKG_BUILD_DIR)/mtd $(IDIR_MTD)/sbin
|
2005-07-21 14:33:05 +03:00
|
|
|
$(RSTRIP) $(IDIR_MTD)/sbin/*
|
2005-07-21 03:27:08 +03:00
|
|
|
$(IPKG_BUILD) $(IDIR_MTD) $(PACKAGE_DIR)
|
2005-09-14 18:30:53 +03:00
|
|
|
|
|
|
|
$(IPKG_MTD_STATIC):
|
|
|
|
install -d -m0755 $(IDIR_MTD_STATIC)/sbin
|
|
|
|
install -m0755 $(PKG_BUILD_DIR)/mtd-static $(IDIR_MTD_STATIC)/sbin
|
|
|
|
$(RSTRIP) $(IDIR_MTD_STATIC)/sbin/*
|
|
|
|
$(IPKG_BUILD) $(IDIR_MTD_STATIC) $(PACKAGE_DIR)
|