Skip to content

CMake error: Invalid escape sequence '\U' in Windows path during ESP8266 RTOS build #5

@akilaid

Description

@akilaid

When building ESP8266 RTOS project using Arduino IDE on Windows, CMake fails due to Windows path backslashes being interpreted as invalid escape sequences. The error occurs during cmake configuration stage as shown below:

-b: /C/Users/holyuser/AppData/Local/Temp/arduino_build_486760
-i: /C/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266                                                                                                                                                                                               RTOS/1.0.3
-x: /C/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/tools/xtensa-lx1                                                                                                                                                                                               06-elf/8_4_0-esp-2020r3
Checking Python dependencies...
Python requirements from C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/requirements.txt are satisfied.
Executing action: all (aliases: build)
Running cmake in directory c:/users/holyuser/appdata/local/temp/arduino_build_486760/idftemplate/build
Executing "cmake -G Ninja -DPYTHON_DEPS_CHECKED=1 -DESP_PLATFORM=1 -DCCACHE_ENABLE=0 c:/users/holyuser/appdata/local/temp/arduino_build_486760/idftemplate"...
-- Found Git: C:/msys32/usr/bin/git.exe (found version "2.19.0")
fatal: not a git repository (or any of the parent directories): .git
-- IDF_TARGET not set, using default target: esp8266
-- The C compiler identification is GNU 8.4.0
-- The CXX compiler identification is GNU 8.4.0
-- The ASM compiler identification is GNU
-- Found assembler: C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/tools/xtensa-lx106-elf/8_4_0-esp-2020r3/bin/xtensa-lx106-elf-gcc.exe
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/tools/xtensa-lx106-elf/8_4_0-esp-2020r3/bin/xtensa-lx106-elf-gcc.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/tools/xtensa-lx106-elf/8_4_0-esp-2020r3/bin/xtensa-lx106-elf-g++.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Project is not inside a git repository,                         will not use 'git describe' to determine PROJECT_VER.
-- Project version: 1
-- Building ESP-IDF components for target esp8266
CMake Deprecation Warning at C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/components/mbedtls/mbedtls/CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Warning (dev) at C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/components/mbedtls/mbedtls/CMakeLists.txt:49 (find_package):
  Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules
  are removed.  Run "cmake --help-policy CMP0148" for policy details.  Use
  the cmake_policy command to set the policy and suppress this warning.

This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found PythonInterp: C:/msys32/mingw32/bin/python.exe (found version "2.7.15")
-- Found Perl: C:/msys32/usr/bin/perl.exe (found version "5.28.0")
-- Adding linker script C:/Users/holyuser/AppData/Local/Temp/arduino_build_486760/idfTemplate/build/esp-idf/esp8266/esp8266_out.ld
-- Adding linker script C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/components/esp8266/ld/esp8266.project.ld.in
-- Adding linker script C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/components/esp8266/ld/esp8266.rom.ld
-- Adding linker script C:/Users/holyuser/AppData/Local/Arduino15/packages/esp8266RTOS/hardware/esp8266RTOS/1.0.3/components/esp8266/ld/esp8266.peripherals.ld
CMake Error at main/CMakeLists.txt:2 (set):
  Syntax error in cmake code at

    C:/Users/holyuser/AppData/Local/Temp/arduino_build_486760/idfTemplate/main/CMakeLists.txt:3

  when parsing string

    C:\Users\holyuser\AppData\Local\Temp\arduino_build_486760\idfTemplate\main\router-addon-v2.ino.cpp

  Invalid character escape '\U'.


-- Configuring incomplete, errors occurred!
cmake failed with exit code 1

This appears to be a path handling issue in the build system when processing Windows-style paths. Any solutions for this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions