[Cmake] CMakeLists with escape sequences

Brad King brad.king at kitware.com
Tue Jul 17 10:20:57 EDT 2001


Hello, all:

I have just checked in code that allows backslash-style escape sequences
in command arguments in CMakeLists.txt files.  The following sequences are
currently supported:

'\\' ==> '\'
'\"' ==> '"'
'\ ' ==> ' '
'\t' ==> tab
'\n' ==> newline
'\r' ==> carriage return
'\0' ==> 0 (ascii value zero)

Other uses of a backslash by itself will produce an error.  All the .cmake
files in the Modules directory have been modified to use the new syntax.

Any CMakeLists files you have that use backslashes in them should be
updated to escape each backslash as you would in C code.

-Brad





More information about the CMake mailing list