using 'ld -r' and limit the exported symbols

Bert Driehuis driehuis at playbeing.org
Wed Jun 23 20:28:28 GMT 2004


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.

If you really want to do it, I think the -r option is pretty much
ubiquitous; if I recall correctly it is used on all Unices in the kernel
build process.

Cheers,

				-- Bert
-- 
Bert Driehuis -- driehuis at playbeing.org -- +31-20-3116119
If the only tool you've got is an axe, every problem looks like fun!


More information about the samba-technical mailing list