X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=package%2Fboot%2Fuboot-lantiq%2FMakefile;h=a021ab03934eabed3ab5b8fb2c126c46a4389352;hb=a64907c4c200f09e2bac5626d06508f61e464e4e;hp=25e6cbbb37fcc94be81ec8876bde4fa278b0fbb2;hpb=e2c0a493fb2db1fbbc5f8cf2275edbd0fab61394;p=openwrt%2Fsvn-archive%2Farchive.git diff --git a/package/boot/uboot-lantiq/Makefile b/package/boot/uboot-lantiq/Makefile index 25e6cbbb37..a021ab0393 100644 --- a/package/boot/uboot-lantiq/Makefile +++ b/package/boot/uboot-lantiq/Makefile @@ -1,22 +1,22 @@ # -# Copyright (C) 2012 OpenWrt.org +# Copyright (C) 2012-2013 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:=2012.07 +PKG_VERSION:=2013.10 PKG_RELEASE:=1 -PKG_SOURCE_PROTO:=git -PKG_SOURCE_URL:=git://dev.phrozen.org/uboot-upstream.git -PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=a0342fc87a884a2f60e2849bcd48fe366ccf9366 -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:= \ + http://mirror2.openwrt.org/sources \ + ftp://ftp.denx.de/pub/u-boot +PKG_MD5SUM:=a076a044b64371edc52f7e562b13f6b2 PKG_TARGETS:=bin PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) @@ -25,41 +25,91 @@ include $(INCLUDE_DIR)/package.mk define uboot/Default TITLE:= - CONFIG:= + SOC:= + DDR_SETTINGS:= IMAGE:= endef define uboot/arv4519pw_ram TITLE:=U-Boot for Arcadyan arv4519pw (RAM) + SOC:=danube DDR_SETTINGS:=board/arcadyan/arv4519pw/ddr_settings.h endef define uboot/arv4519pw_nor TITLE:=U-Boot for Arcadyan arv4519pw (NOR) + SOC:=danube endef define uboot/arv7518pw_ram TITLE:=U-Boot for Arcadyan arv7518pw (RAM) + SOC:=danube DDR_SETTINGS:=board/arcadyan/arv7518pw/ddr_settings.h endef define uboot/arv7518pw_nor TITLE:=U-Boot for Arcadyan arv7518pw (NOR) + SOC:=danube endef define uboot/gigasx76x_ram TITLE:=U-Boot for Siemens Gigaset sx76x (RAM) + SOC:=danube DDR_SETTINGS:=board/gigaset/sx76x/ddr_settings.h endef define uboot/gigasx76x_nor TITLE:=U-Boot for Siemens Gigaset sx76x (NOR) + SOC:=danube +endef + +define uboot/easy50712_ram + TITLE:=U-Boot for Lantiq EASY50712 (RAM) + SOC:=danube + DDR_SETTINGS:=board/lantiq/easy50712/ddr_settings.h +endef + +define uboot/easy50712_nor + TITLE:=U-Boot for Lantiq EASY50712 (NOR) + SOC:=danube +endef + +define uboot/easy50712_norspl + TITLE:=U-Boot for Lantiq EASY50712 (NOR SPL) + SOC:=danube + IMAGE:=u-boot.ltq.lzo.norspl +endef + +define uboot/easy80920_ram + TITLE:=U-Boot for Lantiq EASY80920 (RAM) + SOC:=vr9 + DDR_SETTINGS:=board/lantiq/easy80920/ddr_settings.h endef +define uboot/easy80920_nor + TITLE:=U-Boot for Lantiq EASY80920 (NOR) + SOC:=vr9 +endef + +define uboot/easy80920_norspl + TITLE:=U-Boot for Lantiq EASY80920 (NOR SPL) + SOC:=vr9 + IMAGE:=u-boot.ltq.lzo.norspl +endef + +define uboot/easy80920_sfspl + TITLE:=U-Boot for Lantiq EASY80920 (SPI SPL) + SOC:=vr9 + IMAGE:=u-boot.ltq.lzo.sfspl +endef + + UBOOTS:= \ arv4519pw_ram arv4519pw_nor \ arv7518pw_ram arv7518pw_nor \ - gigasx76x_ram gigasx76x_nor + gigasx76x_ram gigasx76x_nor \ + easy50712_ram easy50712_nor easy50712_norspl \ + easy80920_ram easy80920_nor easy80920_norspl easy80920_sfspl define Package/uboot/template define Package/uboot-lantiq-$(1) @@ -79,37 +129,40 @@ define BuildUBootPackage $(call Package/uboot/template,$(1),$(TITLE)) endef -$(eval $(call uboot/$(BUILD_VARIANT))) +define Build/Configure + $(MAKE) -C $(PKG_BUILD_DIR) $(BUILD_VARIANT)_config +endef define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) $(BUILD_VARIANT) CROSS_COMPILE=$(TARGET_CROSS) -ifneq ($(DDR_SETTINGS),) - awk -f $(PKG_BUILD_DIR)/tools/lantiq_ram_init_uart.awk $(PKG_BUILD_DIR)/$(DDR_SETTINGS) > $(PKG_BUILD_DIR)/$(BUILD_VARIANT)_ddr_settings - perl $(PKG_BUILD_DIR)/tools/gct.pl $(PKG_BUILD_DIR)/$(BUILD_VARIANT)_ddr_settings $(PKG_BUILD_DIR)/u-boot.srec $(PKG_BUILD_DIR)/u-boot.asc -endif + $(MAKE) -C $(PKG_BUILD_DIR) CROSS_COMPILE=$(TARGET_CROSS) endef define Package/uboot/install/default - $(INSTALL_DIR) $(BIN_DIR)/uboot-$(BOARD)-$(1) - $(CP) $(PKG_BUILD_DIR)/u-boot.bin \ - $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot.bin -ifneq ($(DDR_SETTINGS),) - $(CP) $(PKG_BUILD_DIR)/u-boot.asc \ - $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot.asc -endif + $(CP) \ + $(PKG_BUILD_DIR)/$(2) \ + $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot.img endef +define Package/uboot/install/uart + awk -f $(PKG_BUILD_DIR)/tools/lantiq_ram_init_uart.awk \ + -v soc=$(2) $(PKG_BUILD_DIR)/$(3) \ + > $(PKG_BUILD_DIR)/ddr_settings + perl $(PKG_BUILD_DIR)/tools/gct.pl \ + $(PKG_BUILD_DIR)/ddr_settings $(PKG_BUILD_DIR)/u-boot.srec \ + $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot.asc + endef + define Package/uboot/install/template define Package/uboot-lantiq-$(1)/install - $(call Package/uboot/install/default,$(2)) + $(call Package/uboot/install/default,$(1),$(if $(IMAGE),$(IMAGE),u-boot.bin)) + $(if $(DDR_SETTINGS), \ + $(call Package/uboot/install/uart,$(1),$(SOC),$(DDR_SETTINGS)) \ + ) endef endef -$(foreach u,$(UBOOTS), \ - $(eval $(call Package/uboot/install/template,$(u),$(u))) \ -) - $(foreach u,$(UBOOTS), \ $(eval $(call BuildUBootPackage,$(u))) \ + $(eval $(call Package/uboot/install/template,$(u))) \ $(eval $(call BuildPackage,uboot-lantiq-$(u))) \ )