PlatformIO Community

PIO uses forward-slashes instead of back-slashes

Hey gang,
I’m running PIO in VS Code on Windows 10 and developing for ESP32. I was getting the error that xtensa-esp32-elf-gcc.exe was missing. When I checked the directory, it existed… then I realised that PIO had added the path in MS C/C++ Extension with forward-slashes, a Linux syntax that doesn’t work with Windows.
When I changed it to C:\Users\dax.platformio\packages\toolchain-xtensa32\bin\xtensa-esp32-elf-gcc.exe, the error was gone.

I then discovered that all 224 of the Include Paths (Arduino libraries) had forward-slashes. I did a find+replace, but suspect that this will break the next time there is an update to those libraries when PIO attempts to add the paths again.
EDIT: The new error is that the backslashes have been replaced with double-backslashes, which also doesn’t work, of course.

Is there a solution to this to make PIO submit those paths in Windows directory format instead of Linus, please?

All the best,
Dax.

The / pathes that PlatformIO generates work just fine for me, on Windows, with no complaints from VSCode.

grafik

It might be possible that at the time of you checking the folder the file just happened to be finished downloading and VSCode was initially right? When you now delete the .vscode fodler of the project again and do Ctrl+Shift+P → Rebuild Intellisense to regenerate it, does it still complain about the path?