While running my OpenCL code in VC++ 10 by using CMake I am getting the following error:
CMake Error at CMakeLists.txt:6 (set): Syntax error in cmake code at
C:/Users/Shreedhar/Desktop/testCL/CMakeLists.txt:6
when parsing string
C:\Users\Shreedhar\Desktop\test_CL\CMakeLists
Invalid escape sequence \U
Use forward slashes /
in your paths
C:/Users/Shreedhar/Desktop/test_CL/CMakeLists
If you are reading user input like environment variables then you'll need to do this by character replacement feature of string method.
string(REPLACE "\\" "/" outputVar ${_inputVar})
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With