This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.
See the CrossGCC FAQ for lots more infromation.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
> > How do I create an image of an executable suitable for burning into flash? > > I have a .elf, so a file converter would do. > Use objcopy from binutils. Works perfect. thanks > > Or, is there a way to get an ld script to link the .bin in with a > > symbol at the start of the dump? > You can list your .bin as an object on the link line (indicating the input > object format as binary) and use the linker script to direct it where you want > it to go. I'm having trouble making this work. My command line is... arm-elf-gcc -nostartfiles -L../at91 -o main.elf main.o flash.o -bbinary image.bin -T./start.ld -larch And the relevant section of the .ld script is... .rodata : { *(.rodata) *(.rodata.*) *(.gnu.linkonce.r*) image = .; *.bin(*) image_end = .; } > rom I get this error... main.o: file not recognized: File format not recognized arm-elf-gcc: file path prefix `/tools/H-i686-pc-linux-gnu/lib/gcc-lib/binary/2.95.2/' never used make: *** [main.elf] Error 1 It looks like it's trying to interpret my .o files as binarires (when they should be elf object files, I think). How do I link the .o files as object files and the .bin file as a binary? Thanks, Shaun ------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |