The following issue has been SUBMITTED. ====================================================================== http://public.kitware.com/Bug/view.php?id=15134 ====================================================================== Reported By: Mattes D Assigned To: ====================================================================== Project: CMake Issue ID: 15134 Category: CMake Reproducibility: always Severity: minor Priority: normal Status: new ====================================================================== Date Submitted: 2014-09-08 02:47 EDT Last Modified: 2014-09-08 02:47 EDT ====================================================================== Summary: add_subdirectory() fails when CMakeLists.txt in drive root Description: I'm using the "subst" command on windows to make my build folder the root of a separate drive. Thus, the cmake file being processed is called "N:\CMakeLists.txt". CMake then fails to process the file, with several errors, all following the pattern:
CMake Error at N://CMakeLists.txt:66 (add_subdirectory): add_subdirectory not given a binary directory but the given source directory "N:/lib/jsoncpp" is not a subdirectory of "N:/". When specifying an out-of-tree source a binary directory must be explicitly specified. CMake Error at N://CMakeLists.txt:76 (get_property): get_property DIRECTORY scope provided but requested directory was not found. This could be because the directory argument was invalid or, it is valid but has not been processed yet. The very same cmake file, when used in a subfolder, works without a problem. For your reference, the CMakeLists.txt file being used is this one: https://github.com/mc-server/MCServer/blob/562b2d1d1de7438bc763d778b56b0743affd1b5b/CMakeLists.txt Cmake is being called as: cmake -G "Visual Studio 9 2008" . Steps to Reproduce: Use subst to map a folder containing a project to a separate drive letter. Then use CMake in that drive's root to configure the project. CMake fails with the specified error. ====================================================================== Issue History Date Modified Username Field Change ====================================================================== 2014-09-08 02:47 Mattes D New Issue ====================================================================== -- 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-developers