[cmake-developers] Natvis support in Visual Studio
Brad King
brad.king at kitware.com
Fri Jul 15 10:05:27 EDT 2016
On 07/15/2016 09:47 AM, Robert Dailey wrote:
> is Kitware officially using github or gitlab? CMake exists on both
The GitLab repo is used as the issue tracker (recently migrated from Mantis).
The GitHub repo is offered as a convenience for the community but is not
the official path for contribution. See CONTRIBUTING.rst for the documented
official contribution path. GitLab MRs are also allowed but not documented
yet because we're still experimenting with them.
> mapped to object files and call WriteSource() on each of those.
> Currently it seems to support C, CXX, MASM, and RC language types.
> Then there is WriteExtraSources(), which I can only assume is
> "everything else". Is this correct?
Yes. WriteSource() is for first-class language that use enable_language().
Those languages need to be supported by all generators so adding natvis to
it may not make sense.
> If I am correct, would I also be correct to assume that
> WriteExtraSource should be the one to set the XML element name
> (<Natvis>) for *.natvis files based on LANGUAGE being set to NATVIS?
Yes. It already has a table of VS-specific special cases checked by
file extension. See also:
VS: Add a VS_TOOL_OVERRIDE source file property
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ed05f11d
> To add to this confusion, cmVisualStudio7Generator::WriteGroup()
That is only for VS <= 9.
> Somewhere I need to be able to automatically set the LANGUAGE property
> based on file extension.
The LANGUAGE property is meant to be set by projects. If it is not
set then we detect the language. We don't need to explicitly set
the property based on the extension. I think WriteExtraSource is
the only place that needs modification for this.
-Brad
More information about the cmake-developers
mailing list