Next: Libc, Previous: Linker Scripts, Up: Libraries [Contents]
A few ROM monitors load binary images, typically a.out
, but most all
will load an srecord
. An srecord is an ASCII representation of a binary
image. At it’s simplest, an srecord is an address, followed by a byte
count, followed by the bytes, and a 2’s compliment checksum. A whole
srecord file has an optional start record, and a required end
record. To make an srecord from a binary image, the GNU objcopy
program
is used. This will read the image and make an srecord from it. To do
this, invoke objcopy like this: objcopy -O srec infile outfile
. Most
PROM burners also read srecords or a similar format. Use objdump -i
to
get a list of support object files types for your architecture.