2 # Copyright (C) 2010-2012 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
9 include $(INCLUDE_DIR
)/kernel.mk
15 PKG_BUILD_DIR
:=$(KERNEL_BUILD_DIR
)/$(PKG_NAME
)-$(BUILD_VARIANT
)/$(PKG_NAME
)-$(PKG_VERSION
)
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
17 PKG_SOURCE_URL
:=ftp
://ftp.denx.de
/pub
/u-boot
18 PKG_MD5SUM
:=8655f63b1e5c4647295ac9ce44660be3
21 include $(INCLUDE_DIR
)/package.mk
29 define uboot
/sheevaplug
30 TITLE
:=U-Boot for the SheevaPlug
34 TITLE
:=U-Boot for the Seagate DockStar
38 TITLE
:=U-Boot for the Iomega iConnect Wireless
42 TITLE
:=U-Boot for the RaidSonic ICY BOX NAS6210 and NAS6220
45 UBOOTS
:=sheevaplug dockstar iconnect ib62x0
47 define Package
/uboot
/template
48 define Package
/uboot-kirkwood-
$(1)
50 CATEGORY
:=Boot Loaders
51 DEPENDS
:=@TARGET_kirkwood
53 URL
:=http
://www.denx.de
/wiki
/U-Boot
58 define BuildUBootPackage
59 $(eval
$(uboot
/Default
))
61 $(call Package
/uboot
/template
,$(1),$(TITLE
))
65 $(eval
$(call uboot
/$(BUILD_VARIANT
)))
66 UBOOT_CONFIG
:=$(if
$(CONFIG
),$(CONFIG
),$(BUILD_VARIANT
))
67 UBOOT_IMAGE
:=$(if
$(IMAGE
),$(IMAGE
),openwrt-
$(BOARD
)-$(BUILD_VARIANT
)-u-boot.bin
)
70 define Build
/Configure
71 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
72 $(UBOOT_CONFIG
)_config
76 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
78 CROSS_COMPILE
=$(TARGET_CROSS
)
81 define Package
/uboot
/install/default
82 $(INSTALL_DIR
) $(BIN_DIR
)/uboot-
$(BOARD
)-$(1)
83 $(CP
) $(PKG_BUILD_DIR
)/u-boot.bin \
84 $(BIN_DIR
)/uboot-
$(BOARD
)-$(1)/openwrt-
$(BOARD
)-$(1)-u-boot.bin
85 $(CP
) $(PKG_BUILD_DIR
)/u-boot.kwb \
86 $(BIN_DIR
)/uboot-
$(BOARD
)-$(1)/openwrt-
$(BOARD
)-$(1)-u-boot.kwb
87 $(INSTALL_DIR
) $(BIN_DIR
)/u-boot-kwboot
/
88 $(CP
) $(PKG_BUILD_DIR
)/tools
/kwboot \
89 $(BIN_DIR
)/u-boot-kwboot
/
92 define Package
/uboot
/install/template
93 define Package
/uboot-kirkwood-
$(1)/install
94 $(call Package
/uboot
/install/default
,$(2))
98 $(foreach u
,$(UBOOTS
), \
99 $(eval
$(call Package
/uboot
/install/template
,$(u
),$(u
))) \
102 $(foreach u
,$(UBOOTS
), \
103 $(eval
$(call BuildUBootPackage
,$(u
))) \
104 $(eval
$(call BuildPackage
,uboot-kirkwood-
$(u
))) \