]> git.zerfleddert.de Git - proxmark3-svn/blobdiff - bootrom/Makefile
New bootrom
[proxmark3-svn] / bootrom / Makefile
index 43e2533fd0b674250302d61a9fea9dcb647dc0d9..f88b3cdd2598609f5d5150cf1352cfcac8f658bc 100644 (file)
@@ -5,12 +5,19 @@ ARMSRC = fromflash.c
 THUMBSRC = usb.c bootrom.c\r
 ASMSRC = ram-reset.s flash-reset.s\r
 \r
-# Do not move this inclusion before the definition of {THUMB,ASM,ARM}{OBJ,SRC}\r
+## There is a strange bug with the linker: Sometimes it will not emit the glue to call\r
+## BootROM from ARM mode. The symbol is emitted, but the section will be filled with\r
+## zeroes. As a temporary workaround, do not use thumb for the phase 2 bootloader\r
+## -- Henryk Plötz <henryk@ploetzli.ch> 2009-09-01\r
+ARMSRC := $(ARMSRC) $(THUMBSRC)\r
+THUMBSRC := \r
+\r
+# Do not move this inclusion before the definition of {THUMB,ASM,ARM}SRC\r
 include ../common/Makefile.common\r
 \r
 all: $(OBJDIR)/bootrom.s19\r
 \r
-$(OBJDIR)/bootrom.elf: $(ASMOBJ) $(ARMOBJ) $(THUMBOBJ)\r
+$(OBJDIR)/bootrom.elf: $(VERSIONOBJ) $(ASMOBJ) $(ARMOBJ) $(THUMBOBJ)\r
        $(LD) -g -Tldscript-flash --oformat elf32-littlearm -Map=$(patsubst %.elf,%.map,$@) -o $@ $^\r
 \r
 clean:\r
@@ -19,8 +26,9 @@ clean:
        $(DELETE) $(OBJDIR)$(PATHSEP)*.s19\r
        $(DELETE) $(OBJDIR)$(PATHSEP)*.map\r
        $(DELETE) $(OBJDIR)$(PATHSEP)*.d\r
+       $(DELETE) version.c\r
 \r
-.PHONY: all clean help\r
+.PHONY: all clean help \r
 help:\r
        @echo Multi-OS Makefile, you are running on $(DETECTED_OS)\r
        @echo Possible targets:\r
Impressum, Datenschutz