Hello, I'm working on an autotools-based build system and finally decided to look into these messages:
CXXLD libtop.la
copying selected object files to avoid basename conflicts...
It looks like libtool links (copies?) .o files when it finds a dupe in the dependency DAG. Here is the situation I have w.r.t. the dependencies:
libtop.la: liba.la, libx.la
liba.la: libb.la libc.la libx.la
All these libraries are static, noinst_LILIBRARIES and the
dependencies are expressed via _LIBADD syntax:
libtop_la_LIBADD = liba.la libx.la
I do this to get transitive dependencies where the top-level
executable just needs to link to link libtop.la.
I think the issue is with libx.la as it is present in two different branches of the dependency DAG. This kind of thing is common in large projects and seems strange that libtool is trying to be smart about it.
Is there a way to tell automake/libtool to disable this copying and just do straightforward linking? I wonder if the current behavior results in unnecessary bloat?.. Or perhaps I am saved by the linker that would dedup?
Could someone clarify how this is supposed to work for large
projects please?
Thanks!
Oleg.