Invalid character escape '\U'

Using last version clion.
After pio init --ide clion i have error:
Error:Syntax error in cmake code at
C:/Users/Ivan/Documents/esp8266/CMakeListsPrivate.txt:4
when parsing string
C:\Users\Ivan.platformio\packages\toolchain-xtensa\bin\xtensa-lx106-elf-gcc.exe
Invalid character escape ‘\U’.

How i can resolve it?

Do you see here C:/Users/Ivan/Documents/esp8266/CMakeListsPrivate.txt invalid characters?

Invalid character…its my name, maybe :smiley:

For temp solution, i just change slashes in Private.txt.

Example:
Before:
SET(CMAKE_C_COMPILER “C:\Users\Ivan.platformio\packages\toolchain-xtensa\bin\xtensa-lx106-elf-gcc.exe”)
SET(CMAKE_CXX_COMPILER “C:\Users\Ivan.platformio\packages\toolchain-xtensa\bin\xtensa-lx106-elf-g++.exe”)

After:
SET(CMAKE_C_COMPILER “C:/Users/Ivan/.platformio/packages/toolchain-xtensa/bin/xtensa-lx106-elf-gcc.exe”)
SET(CMAKE_CXX_COMPILER “C:/Users/Ivan/.platformio/packages/toolchain-xtensa/bin/xtensa-lx106-elf-g++.exe”)

Maybe we should automatically fix slashes on Windows for CMake? Did it help you?

yeap. Good solution :slight_smile:

Stop! We do that! See
https://github.com/platformio/platformio/blob/develop/platformio/ide/tpls/clion/CMakeListsPrivate.txt.tpl

Could you explain which paths were not replaced?

i don’t know… maybe because generated slash “”? Not \ ?

You can contact with me by skype: ivan6335523, and debuging this bug together :slight_smile:.
My OS Windows 10.

It is escaped. Could you share somewhere CMakeListsPrivate.txt? I’ll take a look on it.

My generated project: http://rgho.st/8hjtngsZX
Generated by command: pio init --ide clion -b nodemcuv2

you downloaded my file?

Yes, this is a bug. Please open an issue here Issues · platformio/platformio-core · GitHub

Okay, i will open issue.

Done:

Thanks! Will fix it tomorrow.

P.S: Good night! :sleeping:

1 Like