This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: objcopy --set-section-flags .data=alloc,load,data,share
- From: Ian Lance Taylor <ian at wasabisystems dot com>
- To: <peter dot kourzanov at xs4all dot nl>
- Cc: binutils at sources dot redhat dot com
- Date: 11 Nov 2004 10:21:48 -0500
- Subject: Re: objcopy --set-section-flags .data=alloc,load,data,share
- References: <1100168375.22757.ezmlm@sources.redhat.com><20041111102549.GP7593@altair.cygnus.nl>
<peter.kourzanov@xs4all.nl> writes:
> I've got a question about semantics of the "share" section flag
> in objcopy. It seems not be documented anywhere and all links I
> could google up refer to COFF binaries, with unexplained semantics
> as well. Is there a possibility to mark a "shared" section in ELF,
> so that OS's that need it can map the section as shared?
The "share" section flag can not be represented in ELF.
I'm not sure exactly what you mean by "map the section as shared," but
the answer is probably no: there is no way to do that in ELF. Note
that typical ELF systems will automatically share read-only text
segments.
Ian