On Thu, 2012-07-05 at 21:31 +0200, Tino Keitel wrote:
I tried building syncevolution with -Wl,--as-needed in LDFLAGS. It
errored out with everal missing symbols from libs like libical. My
understanding is that this is an issue with the liker command line,
which doesn't explicitly contains the required libraries, but relies on
them being implicitly added by other libs which are specified.
The affected libraries can be seen in the build log at
it's the lines starting with "dpkg-shlibdeps".
Furthermore, some the backends seem to use symbols from libs which they
are not linked against, even without " -Wl,--as-needed".
This topic is explained in http://wiki.debian.org/ToolChain/DSOLinking
Do you intend to change this behaviour of the build system so that
-Wl,--as-needed can be used?
Does anything break if it is used?
I've now looked at the build log above in more detail. I see the
warnings from dpkg-shlibdeps. There's certainly room for improvement,
but I am not sure how important those are.
Most of the warnings are about linking too many libs. Partly that's
SyncEvolution's build rules, but partly also seems to come from
third-party .pc files. For example, I have no idea where librt comes
The more serious problems are about syncdav.so not linking to libical
and libsyncevolution.so.0.0.0 not linking against libdl. I'll fix that.
This could become a problem if the executables stop linking against
those. Is that what you see?
I added a compile setup similar to yours as part of the nightly testing
and added some rules to "make installcheck" to catch these linking
issues. The missing libs show up nicely now. However, in practice the
resulting binaries work fine:
Best Regards, Patrick Ohly
The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.