u-boot: rename to uboot
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Mon, 11 Jul 2011 20:46:09 +0000 (22:46 +0200)
committerPeter Korsgaard <jacmet@sunsite.dk>
Mon, 11 Jul 2011 21:39:52 +0000 (23:39 +0200)
This will allow to match the currently Config.in option
BR2_TARGET_UBOOT, in order to make it easy to integrate U-Boot into
the package infrastructure.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
boot/Config.in
boot/u-boot/Config.in [deleted file]
boot/u-boot/u-boot-2010.03-fix-avr32.patch [deleted file]
boot/u-boot/u-boot.mk [deleted file]
boot/uboot/Config.in [new file with mode: 0644]
boot/uboot/uboot-2010.03-fix-avr32.patch [new file with mode: 0644]
boot/uboot/uboot.mk [new file with mode: 0644]

index 67ab8aca4e392d95c4654580cc89d9d5813edd9f..67adae83188d0b754d277e4a94e26fb40fb9fc29 100644 (file)
@@ -3,7 +3,7 @@ menu "Bootloaders"
 source "boot/barebox/Config.in"
 source "boot/grub/Config.in"
 source "boot/syslinux/Config.in"
-source "boot/u-boot/Config.in"
+source "boot/uboot/Config.in"
 source "boot/at91bootstrap/Config.in"
 source "boot/at91dataflashboot/Config.in"
 
diff --git a/boot/u-boot/Config.in b/boot/u-boot/Config.in
deleted file mode 100644 (file)
index aada346..0000000
+++ /dev/null
@@ -1,131 +0,0 @@
-menuconfig BR2_TARGET_UBOOT
-       bool "U-Boot"
-       help
-         Build "Das U-Boot" Boot Monitor
-
-if BR2_TARGET_UBOOT
-config BR2_TARGET_UBOOT_BOARDNAME
-       string "U-Boot board name"
-       help
-         One of U-Boot supported boards to be built.
-         This will be suffixed with _config to meet U-Boot standard naming.
-
-choice
-       prompt "U-Boot Version"
-       default BR2_TARGET_UBOOT_2011_03
-       help
-         Select the specific U-Boot version you want to use
-
-config BR2_TARGET_UBOOT_2011_03
-       bool "2011.03"
-
-config BR2_TARGET_UBOOT_2010_12
-       bool "2010.12"
-
-config BR2_TARGET_UBOOT_2010_09
-       bool "2010.09"
-
-config BR2_TARGET_UBOOT_2010_06
-       bool "2010.06"
-
-config BR2_TARGET_UBOOT_2010_03
-       bool "2010.03"
-
-config BR2_TARGET_UBOOT_CUSTOM_TARBALL
-       bool "Custom tarball"
-
-endchoice
-
-if BR2_TARGET_UBOOT_CUSTOM_TARBALL
-
-config BR2_TARGET_UBOOT_CUSTOM_TARBALL_LOCATION
-       string "URL of custom U-Boot tarball"
-
-endif
-
-config BR2_TARGET_UBOOT_VERSION
-       string
-       default "2011.03"       if BR2_TARGET_UBOOT_2011_03
-       default "2010.12"       if BR2_TARGET_UBOOT_2010_12
-       default "2010.09"       if BR2_TARGET_UBOOT_2010_09
-       default "2010.06"       if BR2_TARGET_UBOOT_2010_06
-       default "2010.03"       if BR2_TARGET_UBOOT_2010_03
-       default "custom"        if BR2_TARGET_UBOOT_CUSTOM_TARBALL
-
-config BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR
-       string "custom patch dir"
-       help
-         If your board requires custom patches, add the path to the
-         directory containing the patches here. The patches must be
-         named u-boot-<version>-<something>.patch.
-
-         Most users may leave this empty
-
-choice
-       prompt "U-Boot binary format"
-
-config BR2_TARGET_UBOOT_FORMAT_BIN
-       bool "u-boot.bin"
-
-config BR2_TARGET_UBOOT_FORMAT_KWB
-       depends on BR2_arm
-       bool "u-boot.kwb (Marvell)"
-
-config BR2_TARGET_UBOOT_FORMAT_LDR
-       depends on BR2_bfin
-       bool "u-boot.ldr"
-
-endchoice
-
-config BR2_TARGET_UBOOT_TOOL_ENV
-       bool "fw_printenv tool in target"
-       help
-         Install fw_printenv / fw_setenv tools in target.
-
-menuconfig BR2_TARGET_UBOOT_NETWORK
-       bool "Network Settings"
-       default y
-       help
-         Network settings for U-boot
-
-if BR2_TARGET_UBOOT_NETWORK
-
-config BR2_TARGET_UBOOT_SERVERIP
-       string "server ip"
-       default "10.175.196.221"
-       help
-         TFTP server ip address
-
-config BR2_TARGET_UBOOT_IPADDR
-       string "ip address"
-       default "10.175.196.18"
-       help
-         Target ip address
-
-config BR2_TARGET_UBOOT_GATEWAY
-       string "gateway ip"
-       default "10.175.196.1"
-       help
-         Gateway ip address
-
-config BR2_TARGET_UBOOT_NETMASK
-       string "netmask"
-       default "255.255.255.0"
-       help
-         Network Mask
-
-config BR2_TARGET_UBOOT_ETHADDR
-       string "ethernet address"
-       default "04:25:fe:ed:00:18"
-       help
-         Target MAC address for the ethernet interface.
-         This should be changed for production units
-
-config BR2_TARGET_UBOOT_ETH1ADDR
-       string "ethernet 2 address"
-       help
-         Target MAC address for the second ethernet interface.
-
-endif # BR2_TARGET_UBOOT_NETWORK
-
-endif # BR2_TARGET_UBOOT
diff --git a/boot/u-boot/u-boot-2010.03-fix-avr32.patch b/boot/u-boot/u-boot-2010.03-fix-avr32.patch
deleted file mode 100644 (file)
index 1f9aab8..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-diff -Naur u-boot-2010.03-orig/include/asm-avr32/unaligned.h u-boot-2010.03/include/asm-avr32/unaligned.h
---- u-boot-2010.03-orig/include/asm-avr32/unaligned.h  1969-12-31 21:00:00.000000000 -0300
-+++ u-boot-2010.03/include/asm-avr32/unaligned.h       2010-06-22 23:09:49.000000000 -0300
-@@ -0,0 +1 @@
-+#include <asm-generic/unaligned.h>
diff --git a/boot/u-boot/u-boot.mk b/boot/u-boot/u-boot.mk
deleted file mode 100644 (file)
index 215b1c7..0000000
+++ /dev/null
@@ -1,129 +0,0 @@
-#############################################################
-#
-# U-Boot
-#
-#############################################################
-U_BOOT_VERSION    = $(call qstrip,$(BR2_TARGET_UBOOT_VERSION))
-U_BOOT_BOARD_NAME = $(call qstrip,$(BR2_TARGET_UBOOT_BOARDNAME))
-
-U_BOOT_INSTALL_IMAGES = YES
-
-ifeq ($(U_BOOT_VERSION),custom)
-# Handle custom U-Boot tarballs as specified by the configuration
-U_BOOT_TARBALL = $(call qstrip,$(BR2_TARGET_UBOOT_CUSTOM_TARBALL_LOCATION))
-U_BOOT_SITE    = $(dir $(U_BOOT_TARBALL))
-U_BOOT_SOURCE  = $(notdir $(U_BOOT_TARBALL))
-else
-# Handle stable official U-Boot versions
-U_BOOT_SITE    = ftp://ftp.denx.de/pub/u-boot
-U_BOOT_SOURCE  = u-boot-$(U_BOOT_VERSION).tar.bz2
-endif
-
-ifeq ($(BR2_TARGET_UBOOT_FORMAT_KWB),y)
-U_BOOT_BIN          = u-boot.kwb
-U_BOOT_MAKE_TARGET  = $(U_BOOT_BIN)
-else ifeq ($(BR2_TARGET_UBOOT_FORMAT_LDR),y)
-U_BOOT_BIN          = u-boot.ldr
-else
-U_BOOT_BIN          = u-boot.bin
-endif
-
-U_BOOT_ARCH=$(KERNEL_ARCH)
-
-# u-boot in the past used arch=ppc for powerpc
-ifneq ($(findstring x2010.03,x$(U_BOOT_VERSION)),)
-U_BOOT_ARCH=$(KERNEL_ARCH:powerpc=ppc)
-endif
-
-U_BOOT_CONFIGURE_OPTS += CONFIG_NOSOFTFLOAT=1
-U_BOOT_MAKE_OPTS += \
-       CROSS_COMPILE="$(CCACHE) $(TARGET_CROSS)" \
-       ARCH=$(U_BOOT_ARCH)
-
-# Helper function to fill the U-Boot config.h file.
-# Argument 1: option name
-# Argument 2: option value
-# If the option value is empty, this function does nothing.
-define insert_define
-$(if $(call qstrip,$(2)),
-       @echo "#ifdef $(strip $(1))" >> $(@D)/include/config.h
-       @echo "#undef $(strip $(1))" >> $(@D)/include/config.h
-       @echo "#endif" >> $(@D)/include/config.h
-       @echo '#define $(strip $(1)) $(call qstrip,$(2))' >> $(@D)/include/config.h)
-endef
-
-ifneq ($(call qstrip,$(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR)),)
-define U_BOOT_APPLY_CUSTOM_PATCHES
-       toolchain/patch-kernel.sh $(@D) $(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR) \
-               u-boot-$(U_BOOT_VERSION)-\*.patch
-endef
-
-U_BOOT_POST_PATCH_HOOKS += U_BOOT_APPLY_CUSTOM_PATCHES
-endif
-
-define U_BOOT_CONFIGURE_CMDS
-       $(TARGET_CONFIGURE_OPTS) $(U_BOOT_CONFIGURE_OPTS)       \
-               $(MAKE) -C $(@D) $(U_BOOT_MAKE_OPTS)            \
-               $(U_BOOT_BOARD_NAME)_config
-       @echo >> $(@D)/include/config.h
-       @echo "/* Add a wrapper around the values Buildroot sets. */" >> $(@D)/include/config.h
-       @echo "#ifndef __BR2_ADDED_CONFIG_H" >> $(@D)/include/config.h
-       @echo "#define __BR2_ADDED_CONFIG_H" >> $(@D)/include/config.h
-       $(call insert_define,DATE,$(DATE))
-       $(call insert_define,CONFIG_LOAD_SCRIPTS,1)
-       $(call insert_define,CONFIG_IPADDR,$(BR2_TARGET_UBOOT_IPADDR))
-       $(call insert_define,CONFIG_GATEWAYIP,$(BR2_TARGET_UBOOT_GATEWAY))
-       $(call insert_define,CONFIG_NETMASK,$(BR2_TARGET_UBOOT_NETMASK))
-       $(call insert_define,CONFIG_SERVERIP,$(BR2_TARGET_UBOOT_SERVERIP))
-       $(call insert_define,CONFIG_ETHADDR,$(BR2_TARGET_UBOOT_ETHADDR))
-       $(call insert_define,CONFIG_ETH1ADDR,$(BR2_TARGET_UBOOT_ETH1ADDR))
-       @echo "#endif /* __BR2_ADDED_CONFIG_H */" >> $(@D)/include/config.h
-endef
-
-ifeq ($(BR2_TARGET_UBOOT_TOOL_ENV),y)
-define U_BOOT_BUILD_TARGET_ENV_UTILS
-       $(TARGET_CONFIGURE_OPTS) $(MAKE) HOSTCC="$(TARGET_CC)" -C $(@D) env
-endef
-endif
-
-define U_BOOT_BUILD_CMDS
-       $(TARGET_CONFIGURE_OPTS) $(U_BOOT_CONFIGURE_OPTS)       \
-               $(MAKE) -C $(@D) $(U_BOOT_MAKE_OPTS)            \
-               $(U_BOOT_MAKE_TARGET)
-       $(U_BOOT_BUILD_TARGET_ENV_UTILS)
-endef
-
-define U_BOOT_INSTALL_IMAGES_CMDS
-       cp -dpf $(@D)/$(U_BOOT_BIN) $(BINARIES_DIR)/
-endef
-
-ifeq ($(BR2_TARGET_UBOOT_TOOL_ENV),y)
-define U_BOOT_INSTALL_TARGET_ENV_UTILS
-       $(INSTALL) -m 0755 -D $(@D)/tools/env/fw_printenv \
-               $(TARGET_DIR)/usr/sbin/fw_printenv
-       ln -sf fw_printenv $(TARGET_DIR)/usr/sbin/fw_setenv
-endef
-endif
-
-define U_BOOT_INSTALL_TARGET_CMDS
-       $(U_BOOT_INSTALL_TARGET_ENV_UTILS)
-endef
-
-$(eval $(call GENTARGETS,boot,u-boot))
-
-#############################################################
-#
-# Toplevel Makefile options
-#
-#############################################################
-ifeq ($(BR2_TARGET_UBOOT),y)
-TARGETS+=u-boot
-
-# we NEED a board name unless we're at make source
-ifeq ($(filter source,$(MAKECMDGOALS)),)
-ifeq ($(U_BOOT_BOARD_NAME),)
-$(error NO U-Boot board name set. Check your BR2_TARGET_UBOOT_BOARDNAME setting)
-endif
-endif
-
-endif
diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in
new file mode 100644 (file)
index 0000000..aada346
--- /dev/null
@@ -0,0 +1,131 @@
+menuconfig BR2_TARGET_UBOOT
+       bool "U-Boot"
+       help
+         Build "Das U-Boot" Boot Monitor
+
+if BR2_TARGET_UBOOT
+config BR2_TARGET_UBOOT_BOARDNAME
+       string "U-Boot board name"
+       help
+         One of U-Boot supported boards to be built.
+         This will be suffixed with _config to meet U-Boot standard naming.
+
+choice
+       prompt "U-Boot Version"
+       default BR2_TARGET_UBOOT_2011_03
+       help
+         Select the specific U-Boot version you want to use
+
+config BR2_TARGET_UBOOT_2011_03
+       bool "2011.03"
+
+config BR2_TARGET_UBOOT_2010_12
+       bool "2010.12"
+
+config BR2_TARGET_UBOOT_2010_09
+       bool "2010.09"
+
+config BR2_TARGET_UBOOT_2010_06
+       bool "2010.06"
+
+config BR2_TARGET_UBOOT_2010_03
+       bool "2010.03"
+
+config BR2_TARGET_UBOOT_CUSTOM_TARBALL
+       bool "Custom tarball"
+
+endchoice
+
+if BR2_TARGET_UBOOT_CUSTOM_TARBALL
+
+config BR2_TARGET_UBOOT_CUSTOM_TARBALL_LOCATION
+       string "URL of custom U-Boot tarball"
+
+endif
+
+config BR2_TARGET_UBOOT_VERSION
+       string
+       default "2011.03"       if BR2_TARGET_UBOOT_2011_03
+       default "2010.12"       if BR2_TARGET_UBOOT_2010_12
+       default "2010.09"       if BR2_TARGET_UBOOT_2010_09
+       default "2010.06"       if BR2_TARGET_UBOOT_2010_06
+       default "2010.03"       if BR2_TARGET_UBOOT_2010_03
+       default "custom"        if BR2_TARGET_UBOOT_CUSTOM_TARBALL
+
+config BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR
+       string "custom patch dir"
+       help
+         If your board requires custom patches, add the path to the
+         directory containing the patches here. The patches must be
+         named u-boot-<version>-<something>.patch.
+
+         Most users may leave this empty
+
+choice
+       prompt "U-Boot binary format"
+
+config BR2_TARGET_UBOOT_FORMAT_BIN
+       bool "u-boot.bin"
+
+config BR2_TARGET_UBOOT_FORMAT_KWB
+       depends on BR2_arm
+       bool "u-boot.kwb (Marvell)"
+
+config BR2_TARGET_UBOOT_FORMAT_LDR
+       depends on BR2_bfin
+       bool "u-boot.ldr"
+
+endchoice
+
+config BR2_TARGET_UBOOT_TOOL_ENV
+       bool "fw_printenv tool in target"
+       help
+         Install fw_printenv / fw_setenv tools in target.
+
+menuconfig BR2_TARGET_UBOOT_NETWORK
+       bool "Network Settings"
+       default y
+       help
+         Network settings for U-boot
+
+if BR2_TARGET_UBOOT_NETWORK
+
+config BR2_TARGET_UBOOT_SERVERIP
+       string "server ip"
+       default "10.175.196.221"
+       help
+         TFTP server ip address
+
+config BR2_TARGET_UBOOT_IPADDR
+       string "ip address"
+       default "10.175.196.18"
+       help
+         Target ip address
+
+config BR2_TARGET_UBOOT_GATEWAY
+       string "gateway ip"
+       default "10.175.196.1"
+       help
+         Gateway ip address
+
+config BR2_TARGET_UBOOT_NETMASK
+       string "netmask"
+       default "255.255.255.0"
+       help
+         Network Mask
+
+config BR2_TARGET_UBOOT_ETHADDR
+       string "ethernet address"
+       default "04:25:fe:ed:00:18"
+       help
+         Target MAC address for the ethernet interface.
+         This should be changed for production units
+
+config BR2_TARGET_UBOOT_ETH1ADDR
+       string "ethernet 2 address"
+       help
+         Target MAC address for the second ethernet interface.
+
+endif # BR2_TARGET_UBOOT_NETWORK
+
+endif # BR2_TARGET_UBOOT
diff --git a/boot/uboot/uboot-2010.03-fix-avr32.patch b/boot/uboot/uboot-2010.03-fix-avr32.patch
new file mode 100644 (file)
index 0000000..1f9aab8
--- /dev/null
@@ -0,0 +1,5 @@
+diff -Naur u-boot-2010.03-orig/include/asm-avr32/unaligned.h u-boot-2010.03/include/asm-avr32/unaligned.h
+--- u-boot-2010.03-orig/include/asm-avr32/unaligned.h  1969-12-31 21:00:00.000000000 -0300
++++ u-boot-2010.03/include/asm-avr32/unaligned.h       2010-06-22 23:09:49.000000000 -0300
+@@ -0,0 +1 @@
++#include <asm-generic/unaligned.h>
diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk
new file mode 100644 (file)
index 0000000..3e945c7
--- /dev/null
@@ -0,0 +1,129 @@
+#############################################################
+#
+# U-Boot
+#
+#############################################################
+UBOOT_VERSION    = $(call qstrip,$(BR2_TARGET_UBOOT_VERSION))
+UBOOT_BOARD_NAME = $(call qstrip,$(BR2_TARGET_UBOOT_BOARDNAME))
+
+UBOOT_INSTALL_IMAGES = YES
+
+ifeq ($(UBOOT_VERSION),custom)
+# Handle custom U-Boot tarballs as specified by the configuration
+UBOOT_TARBALL = $(call qstrip,$(BR2_TARGET_UBOOT_CUSTOM_TARBALL_LOCATION))
+UBOOT_SITE    = $(dir $(UBOOT_TARBALL))
+UBOOT_SOURCE  = $(notdir $(UBOOT_TARBALL))
+else
+# Handle stable official U-Boot versions
+UBOOT_SITE    = ftp://ftp.denx.de/pub/u-boot
+UBOOT_SOURCE  = u-boot-$(UBOOT_VERSION).tar.bz2
+endif
+
+ifeq ($(BR2_TARGET_UBOOT_FORMAT_KWB),y)
+UBOOT_BIN          = u-boot.kwb
+UBOOT_MAKE_TARGET  = $(U_BOOT_BIN)
+else ifeq ($(BR2_TARGET_UBOOT_FORMAT_LDR),y)
+UBOOT_BIN          = u-boot.ldr
+else
+UBOOT_BIN          = u-boot.bin
+endif
+
+UBOOT_ARCH=$(KERNEL_ARCH)
+
+# u-boot in the past used arch=ppc for powerpc
+ifneq ($(findstring x2010.03,x$(UBOOT_VERSION)),)
+UBOOT_ARCH=$(KERNEL_ARCH:powerpc=ppc)
+endif
+
+UBOOT_CONFIGURE_OPTS += CONFIG_NOSOFTFLOAT=1
+UBOOT_MAKE_OPTS += \
+       CROSS_COMPILE="$(CCACHE) $(TARGET_CROSS)" \
+       ARCH=$(UBOOT_ARCH)
+
+# Helper function to fill the U-Boot config.h file.
+# Argument 1: option name
+# Argument 2: option value
+# If the option value is empty, this function does nothing.
+define insert_define
+$(if $(call qstrip,$(2)),
+       @echo "#ifdef $(strip $(1))" >> $(@D)/include/config.h
+       @echo "#undef $(strip $(1))" >> $(@D)/include/config.h
+       @echo "#endif" >> $(@D)/include/config.h
+       @echo '#define $(strip $(1)) $(call qstrip,$(2))' >> $(@D)/include/config.h)
+endef
+
+ifneq ($(call qstrip,$(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR)),)
+define UBOOT_APPLY_CUSTOM_PATCHES
+       toolchain/patch-kernel.sh $(@D) $(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR) \
+               uboot-$(UBOOT_VERSION)-\*.patch
+endef
+
+UBOOT_POST_PATCH_HOOKS += U_BOOT_APPLY_CUSTOM_PATCHES
+endif
+
+define UBOOT_CONFIGURE_CMDS
+       $(TARGET_CONFIGURE_OPTS) $(UBOOT_CONFIGURE_OPTS)        \
+               $(MAKE) -C $(@D) $(UBOOT_MAKE_OPTS)             \
+               $(UBOOT_BOARD_NAME)_config
+       @echo >> $(@D)/include/config.h
+       @echo "/* Add a wrapper around the values Buildroot sets. */" >> $(@D)/include/config.h
+       @echo "#ifndef __BR2_ADDED_CONFIG_H" >> $(@D)/include/config.h
+       @echo "#define __BR2_ADDED_CONFIG_H" >> $(@D)/include/config.h
+       $(call insert_define,DATE,$(DATE))
+       $(call insert_define,CONFIG_LOAD_SCRIPTS,1)
+       $(call insert_define,CONFIG_IPADDR,$(BR2_TARGET_UBOOT_IPADDR))
+       $(call insert_define,CONFIG_GATEWAYIP,$(BR2_TARGET_UBOOT_GATEWAY))
+       $(call insert_define,CONFIG_NETMASK,$(BR2_TARGET_UBOOT_NETMASK))
+       $(call insert_define,CONFIG_SERVERIP,$(BR2_TARGET_UBOOT_SERVERIP))
+       $(call insert_define,CONFIG_ETHADDR,$(BR2_TARGET_UBOOT_ETHADDR))
+       $(call insert_define,CONFIG_ETH1ADDR,$(BR2_TARGET_UBOOT_ETH1ADDR))
+       @echo "#endif /* __BR2_ADDED_CONFIG_H */" >> $(@D)/include/config.h
+endef
+
+ifeq ($(BR2_TARGET_UBOOT_TOOL_ENV),y)
+define UBOOT_BUILD_TARGET_ENV_UTILS
+       $(TARGET_CONFIGURE_OPTS) $(MAKE) HOSTCC="$(TARGET_CC)" -C $(@D) env
+endef
+endif
+
+define UBOOT_BUILD_CMDS
+       $(TARGET_CONFIGURE_OPTS) $(UBOOT_CONFIGURE_OPTS)        \
+               $(MAKE) -C $(@D) $(UBOOT_MAKE_OPTS)             \
+               $(UBOOT_MAKE_TARGET)
+       $(UBOOT_BUILD_TARGET_ENV_UTILS)
+endef
+
+define UBOOT_INSTALL_IMAGES_CMDS
+       cp -dpf $(@D)/$(UBOOT_BIN) $(BINARIES_DIR)/
+endef
+
+ifeq ($(BR2_TARGET_UBOOT_TOOL_ENV),y)
+define UBOOT_INSTALL_TARGET_ENV_UTILS
+       $(INSTALL) -m 0755 -D $(@D)/tools/env/fw_printenv \
+               $(TARGET_DIR)/usr/sbin/fw_printenv
+       ln -sf fw_printenv $(TARGET_DIR)/usr/sbin/fw_setenv
+endef
+endif
+
+define UBOOT_INSTALL_TARGET_CMDS
+       $(UBOOT_INSTALL_TARGET_ENV_UTILS)
+endef
+
+$(eval $(call GENTARGETS,boot,uboot))
+
+#############################################################
+#
+# Toplevel Makefile options
+#
+#############################################################
+ifeq ($(BR2_TARGET_UBOOT),y)
+TARGETS+=u-boot
+
+# we NEED a board name unless we're at make source
+ifeq ($(filter source,$(MAKECMDGOALS)),)
+ifeq ($(UBOOT_BOARD_NAME),)
+$(error NO U-Boot board name set. Check your BR2_TARGET_UBOOT_BOARDNAME setting)
+endif
+endif
+
+endif