[CMake] Why does changing -G not change generators?

David Cole DLRdave at aol.com
Tue Jul 14 11:27:06 EDT 2015


It's just something you can't change without wiping the build tree
entirely. It should probably actually produce an error or warning of
some sort to avoid confusion such as this...

D


On Tue, Jul 14, 2015 at 11:01 AM, Paul Smith <paul at mad-scientist.net> wrote:
> We have a situation where people are sometimes wanting to switch between
> different generators: from Xcode to Unix Makefiles, or from Visual
> Studio 2010 to Visual Studio 2012, etc.
>
> If they have an already-configured workspace then run "cmake -G" with a
> different generator, it appears to be a no-op: no error is generated but
> no changes are made and the previous generator is still used.
>
> This doesn't seem right to me... shouldn't giving a new generator type
> on the command line change the output for the new generator?  I'm using
> CMake 3.1.0... maybe this has changed since?
>
> Cheers!
>
> --
>
> 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


More information about the CMake mailing list