This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: [RFC] Cross core support
- To: Daniel Jacobowitz <dmj+ at andrew dot cmu dot edu>
- Subject: Re: [RFC] Cross core support
- From: Nick Clifton <nickc at cambridge dot redhat dot com>
- Date: 28 Jun 2001 19:04:09 +0100
- Cc: binutils at sources dot redhat dot com
- References: <20010626105035.A7908@nevyn.them.org>
Hi Daniel,
This reply is really more of case of letting you know that your
message did not fall on (entirely) deaf ears. Unfortunately I am
not sure what the best thing to do in this situation is either.
> My inclination is to provide a table for each note type of the total size of
> the note structure on a particular platform and the offsets of the fields we
> are interested in. It seems very unlikely that we would find two notes of
> the same type and the same size on different platforms where all the fields
> we want did not correspond. However, that solution's a little hokey.
Yeah it is a bit hokey. The definitions in the table ought to be
protected with #ifdefs, so that if the table is built on a native
system the values in the table can be compared against the real
values in the procfs.h header and the compilation abort if they are
wrong. That way at least changes in the header will be noticed once
a native build is performed.
> Does anyone know of a counterexample, or a better way to provide the
> necessary information? I suppose it could use a hook in target-specific
> files of BFD, but I'd rather avoid that, since I suppose it would need to be
> added to the bfd vector in that case.
Why would that be a bad thing ? Actually you could add it to the
elf_backend_data structure so you only have to modify ELF ports, and
in fact since they use elfXX-target.h you would only have to modify
the ports that you are interested in.
Cheers
Nick