[CMake] STRING(CONFIGURE ...) problem with too-early variable substitution

Brad King brad.king at kitware.com
Sat Jan 14 14:50:50 EST 2006


Zachary Pincus wrote:
> In my hands (using a CMake CVS build from a week ago), these lines:
> 
> SET(bar "baz")
> SET(foo "\@bar\@")
> MESSAGE("${foo}")
> 
> produces this error:
> 
>> CMake Error: Invalid escape sequence \@

On second thought the @...@ syntax should not be replaced in arguments, 
only by CONFIGURE_FILE or STRING(CONFIGURE).  Please submit a feature 
request here:

http://www.cmake.org/Bug

For now just do

SET(AT @)
SET(foo "${AT}bar${AT}")

-Brad


More information about the CMake mailing list