On Thu, 9 Dec 1999, Simon Wood wrote:

> Hi all,
> I'm still playing around at ELKS and have the idea for a simple loader for a
> diskless psion.
> 
> Take a a.out executable and convert it to a hex dump of the memory it will
> occupy (once loaded) and then transfer it across to the machine, and jump to
> the base location.
> 
> How can I do the expanding bit? Are the tools out there already? Or do I
> have to code it myself?
> 
> Preferably I would like the hex dump to be in the form below, but I am
> flexible on that..
> 00a500:a9f20854c...90
> 00a510:2c51234..ff

In dev86 there's a program called objdump86 it'll dump everything in an
a.out file in text format. Following the word 'TEXTSEG' there's a hex dump
of the text segment following 'DATASEG' there's a hexdump of the data segment.

If the FLAGS have A_SEP it's a seperate I&D evecutable with SS&DS pointing
at the start of the data segment. If FLAGS just has A_EXEC it's an impure
executable and DS:SS:CS all point at the start of the TEXT segment.

BTW: It's actually easy to chop up an a.out file. The *.o files are
     another matter entirely!

-- Rob.                          (Robert de Bath <http://poboxes.com/rdebath>)
                    <rdebath @ poboxes.com> <http://www.cix.co.uk/~mayday>

Reply via email to