Michael Meskes writes ("Guidelines"):
> I think we should make a slight modification to out guidelines. While we ask
> the maintainer to use the ld-flags "-s" to strip the binary, we do not ask
> him to use teh "-s" flag for install, too. However, this flag strips even
> more symbols from te binary. Well, in fact I don't know what it removes
> additionally, the strings are the same, but the binary is smaller after
> being stripped via the strip command (which results in the same binary as
> does the "-s" option for install).
You're right. I propose to change the Guidelines to suggest that:
* C and C++ modules shoould be compiled with -O2 -g.
* Programs should be linked without -s or -g.
* Programs should be installed with -s to strip them fully.
This means that a built source tree contains a binary which is
suitable for debugging, but that this extra information is not
installed on the user's system.
I've found this very useful for dpkg/dselect - coredumps, for example,
are very easy to analyse.
The -g flag doesn't make code generation changes with GCC.
> Also, is a non-stripped binary a bug? I found quite a lot of them while
> installing debian packages. Shame on me, my own quota package belongs to
> that group, too. With large binaries, like the X server, the diffenrence is
Yes, a non-stripped binary is a bug. But, don't report them until
we've come to a conclusion about how packages should be changed ...
- From: Michael Meskes <meskes@Informatik.RWTH-Aachen.DE>