This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GNU ld on x86 Solaris
- To: egcs at cygnus dot com, frichard at bbn dot com
- Subject: Re: GNU ld on x86 Solaris
- From: meissner at cygnus dot com
- Date: Wed, 5 Nov 1997 22:15:37 -0500 (EST)
| I've been tooling around with GNU ld to see if I can get it to work on
| x86 Solaris. I thought this wouldn't be a problem since GNU ld seems
| to work fine on Sparc Solaris. But I'm getting this message:
|
| ld.new: foo: Not enough room for program headers (allocated 5, need 6)
| ld.new: final link failed: Bad value
|
| Here's a complete dump of ld's verbose output. Perhaps I shouldn't be
| using this version of BFD? Any help would be appreciated:
A program header is describes a region of memory to the dynamic linker (IMHO
this is a wart in ELF, that there are two different ways of describing memory,
sections being the other). In any case, for other ELF x86 systems, BFD
believes their will be five regions for programs that contain references to
shared libraries:
1) Program header region that contains the program headers themselves;
2) The interpreter region that points to the interpreter to invoke to
start the program;
3) The read-only, execute enabled text section;
4) The read/write, execute disabled data section;
5) The data passed to the dynamic loader.
If BFD claims it needs 6 tables, then you have an extra section that must be
accounted for (such as r/w data in the middle of r/o data).