aboutsummaryrefslogtreecommitdiffstats
path: root/.gitignore
Commit message (Collapse)AuthorAgeFilesLines
* .gitignore: Undo accidental commit.Daniel Dickinson2010-05-101-0/+3
| | | | SVN-Revision: 21420
* brcm-2.4: Fixed preinit and failsafe switch configurationDaniel Dickinson2010-05-101-3/+0
| | | | SVN-Revision: 21417
* .gitignore: ignore vim swap filesFelix Fietkau2009-12-161-0/+1
| | | | SVN-Revision: 18793
* add logs/ to .gitignoreFelix Fietkau2009-04-241-0/+1
| | | | SVN-Revision: 15364
* add feeds.conf to .gitignoreFelix Fietkau2008-09-231-0/+1
| | | | SVN-Revision: 12658
* add missing gitignore change for build environmentsFelix Fietkau2008-08-061-0/+1
| | | | SVN-Revision: 12213
* update svn:ignore and .gitignoreFelix Fietkau2008-06-061-6/+6
| | | | SVN-Revision: 11381
* add package/openwrt-packages to .gitignoreFelix Fietkau2008-02-091-0/+1
| | | | SVN-Revision: 10429
* add package/feeds to .gitignoreFelix Fietkau2007-10-131-0/+1
| | | | SVN-Revision: 9280
* add feeds to .gitignoreFelix Fietkau2007-10-091-0/+1
| | | | SVN-Revision: 9214
* update svn and git ignore settingsFelix Fietkau2007-08-071-1/+1
| | | | SVN-Revision: 8363
* make top-level .gitignore only apply to top-level files/directories (#1960)Felix Fietkau2007-06-251-8/+8
| | | | SVN-Revision: 7728
* Add gitignore filesFelix Fietkau2007-05-291-0/+8
SVN-Revision: 7385
ighlight">
#
# Copyright (C) 2010 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#

include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk

PKG_NAME:=u-boot
PKG_VERSION:=2010.09
PKG_RELEASE:=1

PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=ftp://ftp.denx.de/pub/u-boot
PKG_MD5SUM:=
PKG_TARGETS:=bin

include $(INCLUDE_DIR)/package.mk

define uboot/Default
  TITLE:=
  CONFIG:=
  IMAGE:=
endef

define uboot/sheevaplug
  TITLE:=U-boot for the Sheevaplug
endef

define uboot/dockstar
  TITLE:=U-boot for the Seagate Dockstar
endef

define uboot/iconnect
  TITLE:=U-boot for the Iomega iConnect Wireless
endef

UBOOTS:=sheevaplug dockstar iconnect

define Package/uboot/template
define Package/uboot-kirkwood-$(1)
  SECTION:=boot
  CATEGORY:=Boot Loaders
  DEPENDS:=@TARGET_kirkwood
  TITLE:=$(2)
  URL:=http://www.denx.de/wiki/U-Boot
  VARIANT:=$(1)
endef
endef

define BuildUbootPackage
	$(eval $(uboot/Default))
	$(eval $(uboot/$(1)))
	$(call Package/uboot/template,$(1),$(TITLE))
endef


ifdef BUILD_VARIANT
$(eval $(call uboot/$(BUILD_VARIANT)))
UBOOT_CONFIG:=$(if $(CONFIG),$(CONFIG),$(BUILD_VARIANT))
UBOOT_IMAGE:=$(if $(IMAGE),$(IMAGE),openwrt-$(BOARD)-$(BUILD_VARIANT)-u-boot.bin)
endif

define Build/Prepare
	$(call Build/Prepare/Default)
	$(CP) ./files/* $(PKG_BUILD_DIR) || true
	find $(PKG_BUILD_DIR) -name .svn | $(XARGS) rm -rf
endef

define Build/Configure
	$(MAKE) -C $(PKG_BUILD_DIR) \
		$(UBOOT_CONFIG)_config
endef

define Build/Compile
	$(MAKE) -C $(PKG_BUILD_DIR) \
		u-boot.kwb \
		CROSS_COMPILE=$(TARGET_CROSS)
endef

define Package/uboot/install/default
	$(INSTALL_DIR) $(BIN_DIR)
	$(CP) $(PKG_BUILD_DIR)/u-boot.bin \
		$(BIN_DIR)/openwrt-$(BOARD)-$(1)-u-boot.bin
	$(CP) $(PKG_BUILD_DIR)/u-boot.kwb \
		$(BIN_DIR)/openwrt-$(BOARD)-$(1)-u-boot.kwb
endef

define Package/uboot/install/template
define Package/uboot-kirkwood-$(1)/install
	$(call Package/uboot/install/default,$(2))
endef
endef

$(foreach u,$(UBOOTS), \
	$(eval $(call Package/uboot/install/template,$(u),$(u))) \
)

$(foreach u,$(UBOOTS), \
	$(eval $(call BuildUbootPackage,$(u))) \
	$(eval $(call BuildPackage,uboot-kirkwood-$(u))) \
)