The following issue has been SUBMITTED. ====================================================================== http://www.cmake.org/Bug/view.php?id=12936 ====================================================================== Reported By: sarnath Assigned To: ====================================================================== Project: CMake Issue ID: 12936 Category: CMake Reproducibility: always Severity: minor Priority: normal Status: new ====================================================================== Date Submitted: 2012-02-06 00:40 EST Last Modified: 2012-02-06 00:40 EST ====================================================================== Summary: ExternalProject_Add - CMAKE_GENERATOR is not passing "-G" option properly Description: I have 2 CMAKE projects. I want one of them to compile as 64 bit application and other as 32-bit application. The 32-bit app is typically a tool that will be used in generating some sources required for the 64-bit compilation. Thats the scenario we have. So, in the 64-bit app, i just "ExternalProject_Add" the 32-bit CMAKE project and use an appropriate generator, say "Visual Studio 9 2008", in the CMAKE_GENERATOR argument. I compile the 64-bit app from native x64 visual studio command prompt with "NMake Makefiles" generator - which builds in 64-bit mode. The CMAKE configuration goes fine. When I do "nmake", I get into errors from devenv command -- resulting from cmake --build of the 32-bit project. devenv reports "Invalid solution configuration". The reason is that the parent CMAKE passes "-GVisual Studio 9 2008" option to the child CMAKE instead of -G "Visual Studio 9 2008". This results in the child cmake using a bad configuration (instead of debug/release).
Steps to Reproduce: Unzip the attached file. IT will create a directory called "cmake_gen_bug". cd into it. cd bin cmake -DCMAKE_VERBOSE_MAKEFILE=on -G "NMake Makefiles" .. nmake Additional Information: This "nmake" would fail with an error message "Invalid solution configuration". It fails regardless of "CMAKE_VERBOSE_MAKEFILE" is ON or OFF. But VERBOSE makefile option will enable us to see what is wrong. Just browse above the "invalid solution configuration" message to the place where parent "cmake" actually calls the child CMAKE. You can see that it calls the child CMAKE with "-GVisual Studio 9 2008" instead of -G "Visual Studio 9 2008". ====================================================================== Issue History Date Modified Username Field Change ====================================================================== 2012-02-06 00:40 sarnath New Issue 2012-02-06 00:40 sarnath File Added: cmake_gen_bug.zip ====================================================================== -- 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://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
