Thanks for the excellent suggestion. Unfortunately we can't really use
for Visual Studio.
The problem is that the two "add_library" calls result in two visual
studio projects. The
problem with this is that our generated Visual Studio solution already
has 300 odd
projects, using you suggestion
Hi David.
In your particular case, you don't have build everything twice. Just make
the SHARED libraries thin wrappers around the OBJECT libraries. Like this:
add_library(obj1 OBJECT a.cpp b.cpp ...)
add_library(lib1 SHARED $)
add_library(obj2 OBJECT c.cpp d.cpp ...)
add_library(lib2 SHARED $)
Currently you can create an OBJECT library using "add_library(
OBJECT ...)" this populates $ which can then
later be used using something like
"target_sources(name PUBLIC $)". I am wondering if
there is some reason that $ can't be populated when
you create a shared or static library, for