Zitat von Dmytro Ovdiienko <[email protected]>:
2009/5/28 Tyler Roscoe <[email protected]>
But from your Lists below it appears that they don't really depend on
one another, in a "target A must be built before target B" sense, but
simply that they use headers from each other's source directories?


A and B are static libraries. The order static libraries building has no
mater.

But you can never ever build shared libraries this way (at least not on all platform). So in fact A and B are one project as one cannot live without the other. Questionable software design, I'd say.

> The other side of this problem is you have to write ADD_SUBDIRECTORY
> commands in specific order. IMHO it is inconvenient.

CMakeLists are essentially a scripting language, so of course order
matters. What would you propose instead?


But... why does TARGET_LINK_LIBRARIES work correctly?

It doesn't. You just think it does because instead of a target name, you can also pass basic non-target library names.
Additionally, static libraries are not linked, so that doesn't matter anyway.

HS


_______________________________________________
Powered by www.kitware.com

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

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

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to