]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
generate u-boot.ldr for Blackfin targets
authorMike Frysinger <vapier@gentoo.org>
Tue, 5 Feb 2008 00:26:57 +0000 (19:26 -0500)
committerMike Frysinger <vapier@gentoo.org>
Tue, 5 Feb 2008 00:26:57 +0000 (19:26 -0500)
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
.gitignore
Makefile
blackfin_config.mk
config.mk

index cda275ec73b289c3c230ff9195ecaae4c800b71a..e29dce92977aa9e8246325c4e59af3ef78501064 100644 (file)
 
 /System.map
 /u-boot
+/u-boot.hex
 /u-boot.map
 /u-boot.bin
 /u-boot.srec
+/u-boot.ldr
+/u-boot.ldr.hex
+/u-boot.ldr.srec
 
 #
 # Generated files
index f6c23417031d9f2d448f528d22b0ce466aa3043f..b4a39945bf05eb65cfce6d4e3cd06ab4fbed0ee2 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -274,6 +274,9 @@ __LIBS := $(subst $(obj),,$(LIBS))
 #########################################################################
 
 ALL += $(obj)u-boot.srec $(obj)u-boot.bin $(obj)System.map $(U_BOOT_NAND)
+ifeq ($(ARCH),blackfin)
+ALL += $(obj)u-boot.ldr
+endif
 
 all:           $(ALL)
 
@@ -286,6 +289,15 @@ $(obj)u-boot.srec: $(obj)u-boot
 $(obj)u-boot.bin:      $(obj)u-boot
                $(OBJCOPY) ${OBJCFLAGS} -O binary $< $@
 
+$(obj)u-boot.ldr:      $(obj)u-boot
+               $(LDR) -T $(CONFIG_BFIN_CPU) -f -c $@ $< $(LDR_FLAGS)
+
+$(obj)u-boot.ldr.hex:  $(obj)u-boot.ldr
+               $(OBJCOPY) ${OBJCFLAGS} -O ihex $< $@ -I binary
+
+$(obj)u-boot.ldr.srec: $(obj)u-boot.ldr
+               $(OBJCOPY) ${OBJCFLAGS} -O srec $< $@ -I binary
+
 $(obj)u-boot.img:      $(obj)u-boot.bin
                ./tools/mkimage -A $(ARCH) -T firmware -C none \
                -a $(TEXT_BASE) -e 0 \
index e91318e9b4db39c0b0a0edd6f384e4adea8f1d3c..a7513ea4dcf81c482b62050219a0e6fa4da443c8 100644 (file)
@@ -25,3 +25,8 @@ PLATFORM_RELFLAGS += -ffixed-P5
 PLATFORM_CPPFLAGS += -DCONFIG_BLACKFIN
 
 SYM_PREFIX = _
+
+LDR_FLAGS += --use-vmas
+ifeq (,$(findstring s,$(MAKEFLAGS)))
+LDR_FLAGS += --quiet
+endif
index 79e5a31b72a6599f027eb0b45df9f95e526b563b..f4312ede6a657ace98bc50307a63daf9c69921f8 100644 (file)
--- a/config.mk
+++ b/config.mk
@@ -121,6 +121,7 @@ CC  = $(CROSS_COMPILE)gcc
 CPP    = $(CC) -E
 AR     = $(CROSS_COMPILE)ar
 NM     = $(CROSS_COMPILE)nm
+LDR    = $(CROSS_COMPILE)ldr
 STRIP  = $(CROSS_COMPILE)strip
 OBJCOPY = $(CROSS_COMPILE)objcopy
 OBJDUMP = $(CROSS_COMPILE)objdump