This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: PATCH: objdump: Skip linker created section
- From: James E Wilson <wilson at specifixinc dot com>
- To: "H. J. Lu" <hjl at lucon dot org>
- Cc: binutils at sources dot redhat dot com
- Date: Tue, 19 Apr 2005 11:15:29 -0700
- Subject: Re: PATCH: objdump: Skip linker created section
- References: <20050417143748.GA25880@lucon.org>
On Sun, 2005-04-17 at 07:37, H. J. Lu wrote:
> Should objdump skip
> linker created section? Readelf doesn't display it.
readelf does not display the section because it doesn't exist in the
object file. Objdump displays the section because we create it always
when bfd initializes, even if not linking. readelf is correct here.
Objdump shouldn't be claiming the section exists.
Perhaps there is a linker hook we can use instead of the elf_object_p
hook? That would fix objdump.
Alternatively, if it is always the case that a section with
SEC_LINKER_CREATED is not in the object file, then your objdump.c patch
looks OK to me. This does appear to be the case, as there is no section
header flag for SEC_LINKER_CREATED, so I think this can only happen for
your fake section group.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com