On Wednesday, October 08, 2014 18:40:53 Nico Schlömer wrote:
> Hi all,
> 
> in on CMake project of mine, all seems to configure fine until the
> very end where I'm getting error messages like
> ```
> CMake Error: install(EXPORT "A" ...) includes target "b" which
> requires target "c" that is not in this export set, but x times in
> others.
> ```
> First of all, CMake does seem to create all files necessary for
> building the project, since that goes without error. Hence, I'm not
> really sure CMake yells at me.
> Second, I don't really understand the message. Indeed, I have a couple
> of export sets in my project, and the libraries there in depend on
> each other. Why the target "c" need to be in the same export set as
> "b"?

It doesn't.
If target c depends on target b, and target c is exported, cmake checks that 
target b is exported too. This is necessary so cmake can put the name of the 
exported "b" library into the dependencies of c.
This is possible if b is exported in the same export set as c, or if b is in a 
different export set, but only in one. Then cmake can use the name of the 
exported target b as it is used in the other export set.
If b is exported in multiple export sets, each of these export sets can use a 
different namespace, and it is not clear which of these different names for b 
should be used as dependency for c.
If b is in only one export set, it will be used with the namespace as used 
there in the list of dependencies of c.

Alex

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to