[En-Nut-Discussion] OPTIONs for ROM/HEX/BIN Generation

Uwe Bonnes bon at elektron.ikp.physik.tu-darmstadt.de
Wed Oct 7 13:24:23 CEST 2009


Hello,

Thu, 19 Feb 2009 with the subject:  Proposed addition to app/Makerules

I tried to discuss the addition of BINFLAGS option to have influence on the
ROM/HEX/BIN generation.  No feedback, proposed patch also not applied. 

Was something wrong with the proposal?

Bye

b.t.w: find the old mail appended.
-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Institut fuer Kernphysik  Schlossgartenstrasse 9  64289 Darmstadt
--------- Tel. 06151 162516 -------- Fax. 06151 164321 ----------
appended patch
- Adds "-R .eeprom" to the rom and bin target
- Adds a BINFLAGS variable  to the hex/rom/bin target

The BINFLAG comes handy if the local Makefile defines additional sections
like:

LDFLAGS += -Wl,--section-start=.aram=0x801100 
LDFLAGS += -Wl,--section-start=.fpga=0x80e000

and these sections should be exclude from the targets too, like

BINFLAGS += -R .aram -R .fpga

Fore me, .aram is additional RAM memory and memory mapped FPGA registers,
that are only detected in main().

Any comments?

Thanks
-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Institut fuer Kernphysik  Schlossgartenstrasse 9  64289 Darmstadt
--------- Tel. 06151 162516 -------- Fax. 06151 164321 ----------
Index: app/Makerules.avr-gcc
===================================================================
--- app/Makerules.avr-gcc       (Revision 970)
+++ app/Makerules.avr-gcc       (Arbeitskopie)
@@ -53,13 +53,13 @@
        $(ELFCOF) -O coff-ext-avr $< $@
 
 %hex: %elf
-       $(BIN) -R .eeprom -O ihex $< $@
+       $(BIN) -R .eeprom $(BINFLAGS) -O ihex $< $@
 
 %rom: %elf
-       $(BIN) -O ihex $< $@
+       $(BIN) -R .eeprom $(BINFLAGS) -O ihex $< $@
 
 %bin: %elf
-       $(BIN) -O binary $< $@
+       $(BIN) -R .eeprom $(BINFLAGS) -O binary $< $@
 
 %eep: %elf
        $(BIN) -j .eeprom --set-section-flags=.eeprom="alloc,load" --change-section-lma .eeprom=0 -O ihex $< $@
_______________________________________________



More information about the En-Nut-Discussion mailing list