CreateProcess: No such file or directory

I have been using PIO on a project for months and it worked great. I have been storing my project on github with just a gitignore of .pio and .vscode. My computer died and I have cloned the repo onto a new machine with newly installed vscode and pio. Now it won’t compile. I did a clean and then build from the bottom of vscode.

All of the files mentioned in the error exist in .cpp form. Here is the output …

PLATFORM: Espressif 8266 (2.6.2) > WeMos D1 R2 and mini
HARDWARE: ESP8266 80MHz, 80KB RAM, 4MB Flash
 - framework-arduinoespressif8266 3.20704.0 (2.7.4)
 - tool-esptool 1.413.0 (4.13)
 - tool-esptoolpy 1.20800.0 (2.8.0)
 - toolchain-xtensa 2.40802.200502 (4.8.2)
LDF: Library Dependency Finder ->
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 30 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <LittleFS(esp8266)> 0.1.0
|-- <ESP8266WiFi> 1.0        
|-- <ESP8266HTTPClient> 1.2  
|   |-- <ESP8266WiFi> 1.0    
|-- <ESP8266httpUpdate> 1.3
|   |-- <ESP8266HTTPClient> 1.2
|   |   |-- <ESP8266WiFi> 1.0
|   |-- <ESP8266WiFi> 1.0
Building in release mode
Compiling .pio\build\nodemcuv2\src\command.cpp.o
Compiling .pio\build\nodemcuv2\src\files.cpp.o
xtensa-lx106-elf-g++: error: CreateProcess: No such file or directory

vscode version: 1.52.1
pio version: Core 5.0.4, Home 3.3.1

Is there something else I am supposed to be installing?

You might have a corrupted toolchain. Please remove the folder C:\Users\<user>\.platformio\packages\toolchain-xtensa completely and rebuild.

If in doubt, check if disabligg the antivirus makes a difference.

EDIT: corrected path.

1 Like

There is no toochain-xtensa in .platformio. It only has appstate.json homestate.json packages penv platforms python3. Is this a clue to the problem?

I just started vscode and saw this …

Unable to resolve configuration with compilerPath: "C:/Users/mlap/.platformio/packages/toolchain-xtensa/bin/xtensa-lx106-elf-gcc.exe"

I don’t know if this happened before.

I just tried compiling with virus protection off and it didn’t change anything.

Is there some way to tell what file is missing that the error refers to?

I meant this path, I was missing a packages. The error message is telling you the same: The compiler is not there.

1 Like

Thanks, that worked.