[CMake] List of Commands/Constants/Keywords

Brandon J. Van Every bvanevery at gmail.com
Sun Nov 19 12:38:37 EST 2006


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})



Cheers,
Brandon Van Every



More information about the CMake mailing list