[CMake] Convenience lib vs static library
post at hendrik-sattler.de
Sun Nov 23 06:51:35 EST 2008
Am Sunday 23 November 2008 10:35:03 schrieb Andreas Pakulat:
> On 23.11.08 11:24:23, Ioan Calin Borcoman wrote:
> > Would it be possible to add support for libtool in a cmake module? I
> > understand that this would be against cmake's policy of not depending
> > on external apps, but it could be a transient solution until full
> > fledged support for convenience libs is added into cmake.
> PS: What has been discussed (and afaik even requested via cmake's
> bugtracker) is to allow access to the actual created object files. That
> way you could have the same files included in >1 shared library and would
> still save the compilation time.
Yes. Something like a unlinked (virtual) library. Depending on it would not
link that library but its object files. Shouldn't be that complicated but has
its pitfalls: position independent code (PIC) is used for object going to a
shared library but not for objects going to an executable or static library
(unless you want to link the static library into a shared library).
OTOH: including the same objects into different libraries defeats the purpose
of shared libraries.
More information about the CMake