[cmake-developers] cmake -E capabilities

Brad King brad.king at kitware.com
Thu Jun 30 15:00:17 EDT 2016


On 06/30/2016 09:51 AM, Tobias Hunger wrote:
> Compared to the bug report mentioned above the fields "multiconfig" and
> "recursive" are missing. I could not figure out how to get that information:-/

There is no "recursive" generator, so that does not belong in the example
anyway.  The Makefile generator does not produce recursive makefiles:

 https://cmake.org/Wiki/CMake_FAQ#Why_does_CMake_generate_recursive_Makefiles.3F

For "multiconfig", there is the cmGlobalGenerator::IsMultiConfig method.
Something similar will have to be added to the generator factory APIs
so that we can ask for this information without creating a generator.

> I could also not yet figure out a way to retrieve information on supported
> platforms and toolsets. At least I did get whether a generator supports
> toolsets, but nothing similar seems to exist for the platform part.

We don't have any information on supported platforms or toolsets.
The CMAKE_GENERATOR_PLATFORM and CMAKE_GENERATOR_TOOLSET settings
take user-specified values and we pass them through to native tools.
It is up to the user to provide valid values.

However, we can at least report whether the platform/toolset options
are supported by a given generator.  For this one could add APIs to
generator factories as mentioned above for multiconfig.

-Brad



More information about the cmake-developers mailing list