public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Adding library info to elf shared object
@ 2009-12-17 16:51 erik.rull
  2009-12-18 15:28 ` Ian Lance Taylor
  0 siblings, 1 reply; 6+ messages in thread
From: erik.rull @ 2009-12-17 16:51 UTC (permalink / raw)
  To: gcc-help

Hi all,

I'm searching for a possibility to add a (length limited) text comment to a
shared object file so that a program is able to read them out and display
them to the user. I need just something additional to the filename and
soname that describes the shared object.

Any ideas how to approach?

I want to use it for linux i386.

Thanks!

Best regards,

Erik

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Adding library info to elf shared object
  2009-12-17 16:51 Adding library info to elf shared object erik.rull
@ 2009-12-18 15:28 ` Ian Lance Taylor
  2010-01-04  0:25   ` Erik Rull
  0 siblings, 1 reply; 6+ messages in thread
From: Ian Lance Taylor @ 2009-12-18 15:28 UTC (permalink / raw)
  To: erik.rull; +Cc: gcc-help

erik.rull@rdsoftware.de writes:

> I'm searching for a possibility to add a (length limited) text comment to a
> shared object file so that a program is able to read them out and display
> them to the user. I need just something additional to the filename and
> soname that describes the shared object.

See objcopy --add-section.

Ian

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Adding library info to elf shared object
  2009-12-18 15:28 ` Ian Lance Taylor
@ 2010-01-04  0:25   ` Erik Rull
  2010-01-04 18:46     ` Ian Lance Taylor
  0 siblings, 1 reply; 6+ messages in thread
From: Erik Rull @ 2010-01-04  0:25 UTC (permalink / raw)
  To: Ian Lance Taylor; +Cc: gcc-help

Ian Lance Taylor wrote:
> erik.rull@rdsoftware.de writes:
> 
>> I'm searching for a possibility to add a (length limited) text comment to a
>> shared object file so that a program is able to read them out and display
>> them to the user. I need just something additional to the filename and
>> soname that describes the shared object.
> 
> See objcopy --add-section.
> 
> Ian

Hi Ian,

thanks a lot! Are there any possibilities to do that operation with gcc / 
ld directly during linkage process? Would make life easier :-)
An option like the adding of the .so - name to the shared library content.

Best regards,

Erik

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Adding library info to elf shared object
  2010-01-04  0:25   ` Erik Rull
@ 2010-01-04 18:46     ` Ian Lance Taylor
  2010-01-06 23:12       ` Erik Rull
  0 siblings, 1 reply; 6+ messages in thread
From: Ian Lance Taylor @ 2010-01-04 18:46 UTC (permalink / raw)
  To: Erik Rull; +Cc: gcc-help

Erik Rull <erik.rull@rdsoftware.de> writes:

> Ian Lance Taylor wrote:
>> erik.rull@rdsoftware.de writes:
>>
>>> I'm searching for a possibility to add a (length limited) text comment to a
>>> shared object file so that a program is able to read them out and display
>>> them to the user. I need just something additional to the filename and
>>> soname that describes the shared object.
>>
>> See objcopy --add-section.
>>
>> Ian
>
> Hi Ian,
>
> thanks a lot! Are there any possibilities to do that operation with
> gcc / ld directly during linkage process? Would make life easier :-)
> An option like the adding of the .so - name to the shared library content.

See the .incbin assembler directive.

Ian

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Adding library info to elf shared object
  2010-01-04 18:46     ` Ian Lance Taylor
@ 2010-01-06 23:12       ` Erik Rull
  2010-01-07  0:36         ` Ian Lance Taylor
  0 siblings, 1 reply; 6+ messages in thread
From: Erik Rull @ 2010-01-06 23:12 UTC (permalink / raw)
  To: Ian Lance Taylor; +Cc: gcc-help

Ian Lance Taylor wrote:
> Erik Rull <erik.rull@rdsoftware.de> writes:
> 
>> Hi Ian,
>>
>> thanks a lot! Are there any possibilities to do that operation with
>> gcc / ld directly during linkage process? Would make life easier :-)
>> An option like the adding of the .so - name to the shared library content.
> 
> See the .incbin assembler directive.
> 
> Ian

Hi Ian,

err - is that cross-platform compatible? I want this to work with ARM and 
x86...

Erik

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Adding library info to elf shared object
  2010-01-06 23:12       ` Erik Rull
@ 2010-01-07  0:36         ` Ian Lance Taylor
  0 siblings, 0 replies; 6+ messages in thread
From: Ian Lance Taylor @ 2010-01-07  0:36 UTC (permalink / raw)
  To: Erik Rull; +Cc: gcc-help

Erik Rull <erik.rull@rdsoftware.de> writes:

> Ian Lance Taylor wrote:
>> Erik Rull <erik.rull@rdsoftware.de> writes:
>>
>>> Hi Ian,
>>>
>>> thanks a lot! Are there any possibilities to do that operation with
>>> gcc / ld directly during linkage process? Would make life easier :-)
>>> An option like the adding of the .so - name to the shared library content.
>>
>> See the .incbin assembler directive.
>>
>> Ian
>
> Hi Ian,
>
> err - is that cross-platform compatible? I want this to work with ARM
> and x86...

Yes, assuming you are using the GNU assembler.  It works for any GNU
assembler target.

Ian

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-01-07  0:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-17 16:51 Adding library info to elf shared object erik.rull
2009-12-18 15:28 ` Ian Lance Taylor
2010-01-04  0:25   ` Erik Rull
2010-01-04 18:46     ` Ian Lance Taylor
2010-01-06 23:12       ` Erik Rull
2010-01-07  0:36         ` Ian Lance Taylor

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).