linux - elf file thinks its small, but its large! can not generate .bin and .hex files -


i working on migrating project kail gcc.

makefile http://www.copypastecode.com/73860/ .ld file http://www.copypastecode.com/73856/

i have makefile , platform.ld script , .c , .h files. when make, compiles , links , looks good.

arm-none-eabi-size -b output/stm32_gps_test.elf

text    data   bss      dec     hex filename   0       0    2048    2048     800 output/stm32_gps_test.elf 

but when check generated files see this:

ls output/

7327274 2011-07-02 04:28 stm32_gps_test.elf 0 2011-07-02 04:28 stm32_gps_test.bin 34 2011-07-02 04:28 stm32_gps_test.hex 

and:

tail output/stm32_gps_test.hex

:0400000508000000ef :00000001ff 

some info on elf file:

arm-none-eabi-readelf -h output/stm32_gps_test.elf

elf header:   magic:   7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00    class:                             elf32   data:                              2's complement, little endian   version:                           1 (current)   os/abi:                            unix - system v   abi version:                       0   type:                              exec (executable file)   machine:                           arm   version:                           0x1   entry point address:               0x8000000   start of program headers:          52 (bytes file)   start of section headers:          7323752 (bytes file)   flags:                             0x5000002, has entry point, version5 eabi   size of header:               52 (bytes)   size of program headers:           32 (bytes)   number of program headers:         1   size of section headers:           40 (bytes)   number of section headers:         18   section header string table index: 15 

what wrong? have tried run objcopy create binfile , hexfile result same.

when disassemble see? (objdump -d) if have example rom image @ 0x80000000 , ram @ 0x20000000 .bin file objcopy @ minimum 0x60000000 bytes plus size of image in rom. intel hex file or srec should work though.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -