(1) how to hide helper classes (2) KDE_NO_INLINE missing?

Dr. Juergen Pfennig info at j-pfennig.de
Sun Mar 7 17:11:18 GMT 2004

On Sunday 07 March 2004 14:12, Dirk Mueller wrote:
> The other recommended way is to use a linker version script. There are
> plenty of libraries that could make use of it, the most prominent example
> is libkdeprint, since 98% of its symbols are private API, which is not
> properly namespaced and often causes conflicts with symbols with the same
> name in userspace code. a linker version script avoids unnecessary symbols
> (reduces symbol conflicts and helps relocation speed), but it does not
> reduce the calling overhead, since the compiler doesn't know that a symbol
> isn't going to be exported.

Hi Dirk
thanks for the tip, this was exactly what I have been searching for. For the 
kio_ftp.so (which is not a very good example for the technique) the figures 

93.137 bytes without version script
90.721 bytes using a linker version script

more infos:
70.800 bytes after "strip --strip-unneeded"
40.000 bytes (approx.) in .text, see objdump

Here is my very simple version script (to demonstrate how simple it is):

  extern "C++" {

My conclusion: about 30% of the installed binary data are symbol tables that 
are not needed. Programmers might use version scripts but how does this 
affect debugging?

Is it bad to use strip? I could do it for kio_ftp and it still works. Could 
packagers do this before they package their stuff?


More information about the kde-core-devel mailing list