* exporting symbols in shared libraries
@ 2002-10-24 10:10 thomas joseph
2002-10-24 11:52 ` Fergus Henderson
2002-10-24 13:04 ` Phil Edwards
0 siblings, 2 replies; 4+ messages in thread
From: thomas joseph @ 2002-10-24 10:10 UTC (permalink / raw)
To: gcc
Hi All,
I have a small question to you.
Could some body tell me how do I stop exporting
a symbol in a shared libraries using gcc.
I do n't want to make it static. Because I need to
access it from other files.
Is there any compiler option/construct to support
this.
Thanks in advance,
best regards,
--thomas
http://careers.yahoo.com.au - Yahoo! Careers
- 1,000's of jobs waiting online for you!
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: exporting symbols in shared libraries
2002-10-24 10:10 exporting symbols in shared libraries thomas joseph
@ 2002-10-24 11:52 ` Fergus Henderson
2002-10-24 13:04 ` Phil Edwards
1 sibling, 0 replies; 4+ messages in thread
From: Fergus Henderson @ 2002-10-24 11:52 UTC (permalink / raw)
To: thomas joseph; +Cc: gcc
On 24-Oct-2002, thomas joseph <thomascanny@yahoo.co.nz> wrote:
>
> Hi All,
> I have a small question to you.
> Could some body tell me how do I stop exporting
> a symbol in a shared libraries using gcc.
>
> I do n't want to make it static. Because I need to
> access it from other files.
> Is there any compiler option/construct to support
> this.
In the latest (CVS) versions of gcc, you can use the visibility attribute,
e.g. __attribute__((visibility(hidden))). This only works for ELF targets,
AFAIK.
--
Fergus Henderson <fjh@cs.mu.oz.au> | "I have always known that the pursuit
The University of Melbourne | of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: exporting symbols in shared libraries
2002-10-24 10:10 exporting symbols in shared libraries thomas joseph
2002-10-24 11:52 ` Fergus Henderson
@ 2002-10-24 13:04 ` Phil Edwards
1 sibling, 0 replies; 4+ messages in thread
From: Phil Edwards @ 2002-10-24 13:04 UTC (permalink / raw)
To: thomas joseph; +Cc: gcc
On Thu, Oct 24, 2002 at 10:56:01PM +1300, thomas joseph wrote:
>
> Hi All,
> I have a small question to you.
> Could some body tell me how do I stop exporting
> a symbol in a shared libraries using gcc.
Usually this is done by the linker, not the compiler. See your linker's
documentation on symbol maps.
Phil
--
I would therefore like to posit that computing's central challenge, viz. "How
not to make a mess of it," has /not/ been met.
- Edsger Dijkstra, 1930-2002
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: exporting symbols in shared libraries
@ 2002-10-24 15:30 Rayson Ho
0 siblings, 0 replies; 4+ messages in thread
From: Rayson Ho @ 2002-10-24 15:30 UTC (permalink / raw)
To: gcc; +Cc: thomascanny
>
> Hi All,
> I have a small question to you.
> Could some body tell me how do I stop exporting
> a symbol in a shared libraries using gcc.
You can use "version script", or "Linker Mapfile":
http://www.gnu.org/manual/ld-2.9.1/html_node/ld_25.html
http://soldc.sun.com/articles/linker_mapfiles.html
Rayson
__________________________________________________
Do you Yahoo!?
Y! Web Hosting - Let the expert host your web site
http://webhosting.yahoo.com/
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-10-24 16:06 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-24 10:10 exporting symbols in shared libraries thomas joseph
2002-10-24 11:52 ` Fergus Henderson
2002-10-24 13:04 ` Phil Edwards
2002-10-24 15:30 Rayson Ho
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).