using 'ld -r' and limit the exported symbols

Stefan (metze) Metzmacher metze at samba.org
Wed Jun 23 22:18:58 GMT 2004


Bert Driehuis schrieb:

> On Wed, 23 Jun 2004, Stefan (metze) Metzmacher wrote:
> 
> 
>>I just found out about the 'ld -r' option which is used for prelinking.
>>this is used by th elinux kernel for creating only one .o file for a
>>subsystem.
>>
>>I think it would be very usefull to use it in samba4 too, if the linker
>>supports it.
> 
> 
> Just out of curiosity -- why?
> 
> Unless I'm seriously mistaken, it doesn't buy any performance, it will
> complicate the build process, and it probably will make debugging one
> notch harder. The only gain I see is reduced diskspace, which is why
> embedded systems use tricks like this.

I don't want to reduce the binary size,
what I want to do is having private functions inside a subsystem, which 
should not be accessable by other parts, in the same way we often use
'static' function which are private only to one source file.

the debug symbols should not be changed, so a debugger will work the 
same way as before...





-- 
metze

Stefan Metzmacher <metze at samba.org> www.samba.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 194 bytes
Desc: OpenPGP digital signature
Url : http://lists.samba.org/archive/samba-technical/attachments/20040624/9908167e/signature.bin


More information about the samba-technical mailing list