On 01/12/2011 11:47 PM, Manuel Klimek wrote:
> Split up the patch - apparently I need ssh access to push the topic
> stuff, so I'm just attaching the patches.

Thanks.  That's pretty clean.  In the final version of this topic please
add one more intermediate commit that optimizes GetFlags and GetDefines
to cache their result for each language.  Otherwise they get invoked
once for the target (as in current CMake) plus once for each source file
(after the second patch).

About the name "cxx_commands.json" of the file:  I'd like to hide this
away from the casual user by putting it in the CMakeFiles subdirectory.
The commands can be for compilation of any language so it should be
called something like "CMakeFiles/compile_commands.json" instead.

About the content of the json file: I suggest that each command also
include a "language" field indicating "C", "C++", or "Fortran".  That
will help tools know how to treat the file named by the "file" field.
One might also include a "target" field indicating the name of the
logical target to which it belongs.  I don't know whether this is
useful in your case or not.

-Brad
_______________________________________________
cmake-developers mailing list
cmake-developers@cmake.org
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to