[cmake-developers] Generating buildsystem metadata from CMake

Stephen Kelly steveire at gmail.com
Sat Mar 21 05:14:58 EDT 2015


Tobias Hunger wrote:

> On Wed, Mar 11, 2015 at 11:10 AM, Stephen Kelly
> <steveire at gmail.com> wrote:
>> * Make it possible for editors/IDEs to allow specifying the configuration
>>   at build-time, where the IDE has that feature, and where a multi-config
>>   generator is available.  That is, QtCreator provides user-interface for
>>   choosing debug/release config to build.  Currently it can't offer that
>>   when using cmake, because it only allows the use of Makefile or Ninja
>>   generators, in order to make use of the C::B file.  QtCreator should be
>>   able to use the Xcode or Visual Studio generators, generate the
>>   metadata file(s), and invoke `cmake --build . --config ${CONFIG}` as
>>   appropriate.  Eclipse, Sublime and other editors have similar abilities
>>   to invoke config-specific builds after generation.
> 
> We can offer debug/release even with different build directories in
> Creator. Those are just labels on the build configuration that
> includes the build directory and the configuration to be set up in
> that build.

Interesting. Is that already the case in Creator?

> For the other build systems it is completely safe to just nuke any
> build directory and creator will re-initialize it on the next build.
> That is unfortunately not the case with cmake at this time though: If
> you nuke a cmake build directory then creator will be completely lost
> about how to regenerate the configuration again.

Ah, is this why you asked before for the command line options passed to 
cmake before?

Why is it safe with other buildsystems but not cmake to nuke the build dir?

Thanks,

Steve.




More information about the cmake-developers mailing list