Is there a reason, why you treat your independent projects with add_directory() instead of making them external projects?
-- Gruesse, Jakub From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Aurelien Richez Sent: Donnerstag, 27. März 2014 14:58 To: cmake@cmake.org Subject: [CMake] target name collision Hi, I have two project that are independent and can be compiled on their own. I also have a bigger project which include these two project with add_subdirectory. However, these projects contain targets with the same names. As a consequence, cmake 2.8 complains with a message such as "another target with the same name already exists" when I try to generate the makefile. Isn't there a way to handle this situation which does not involve renaming the targets in the subproject ? Like an option to automatically add a prefix to target added from add_subdirectory (for instance, target "doc" in "subproject1" would become "subproject1/doc" in the upper project). Thanks, Aurélien Richez
-- 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://www.cmake.org/mailman/listinfo/cmake