[CMake] List of Commands/Constants/Keywords
Bill Hoffman
bill.hoffman at kitware.com
Sun Nov 19 13:44:26 EST 2006
Brandon J. Van Every wrote:
> Mike Jackson wrote:
>> Is there a way to generate the list of Cmake keywords/Constants/Commands
>> that can appear in a Cmake file? I am trying to write a language
>> definition
>> for TextMate on OS X and a list of these would make life simpler.
>>
>> I seem to remember a posting about this to the list but I am not
>> coming up
>> with the right search string to find it again.
>>
>
> I remember that post as well. This is what I saved and have
> occasionally used. I do not know if it's comprehensive.
>
>
> FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt "")
> GET_CMAKE_PROPERTY(res VARIABLES)
> FOREACH(var ${res})
> FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt
> "${var} \"${${var}}\"\n")
> ENDFOREACH(var ${res})
>
>
I don't think this is what you want for a cmake mode in an editor.
cmake --help-commands will list all available commands. There are also
emacs and vim modes that can be found here:
http://www.cmake.org/HTML/Download.html
They might be good places to start. I think the emacs mode just looks
for foo(...),
and has information about if and other control commands.
-Bill
More information about the CMake
mailing list