ESPHome always has compilation error

Hi,

i am running EPSHome on my Home Assistant on Raspberry Pi 4.

The wireless installing of my ESP8266 always fails.

Log:

> INFO ESPHome 2025.10.1
> INFO Reading configuration /config/esphome/esp-led-decke2.yaml...
> INFO Generating C++ source...
> INFO Compiling app...
> Processing esp-led-decke2 (board: esp01_1m; framework: arduino; platform: platformio/[email protected])
> --------------------------------------------------------------------------------
> HARDWARE: ESP8266 80MHz, 80KB RAM, 1MB Flash
> Dependency Graph
> |-- ESPAsyncTCP @ 2.0.0
> |-- ESP8266WiFi @ 1.0
> |-- ESPAsyncWebServer @ 3.7.10
> |-- DNSServer @ 1.1.1
> |-- ESP8266mDNS @ 1.2
> |-- noise-c @ 0.1.10
> |-- NeoPixelBus @ 2.7.3
> Compiling .pioenvs/esp-led-decke2/src/esphome/components/api/api_connection.cpp.o
> xtensa-lx106-elf-g++: fatal error: braced spec 'AtM<MM:cc1plus -E %(cpx_options) %2 %(cpp_debug_optmons)}%{!U:%{!M:%{!-M:  %{savd-teops*|no-integratee-crp:cc1p|us \x0dE\x09   %(bpp_options) %2\xb0-o e{save-temps*:-b.ii} %o!sav%-temps(:5g\x0eii]`\x0a}  cc1xlus %{save-temps*|no-integr!ted-cpp:-\xeepretzoc\xe5ssed \x09   %ysavm-vemps*:%".ii} %{!save-tem`s*:%g.ii}}` %\x7f!sAve,temps*:%{!no-integrated-cpP:%(cpp_qnique_options)}}\x89 %(cc1Woptions) '2  %{!fq9ntax-onlY:\x05(\xednvo\xeaa_a{)}}}}' is invalid at '<'
> compilation terminated.
> Compiling .pioenvs/esp-led-decke2/src/esphome/components/api/api_frame_helper.cpp.o
> *** [.pioenvs/esp-led-decke2/src/esphome/components/api/api_connection.cpp.o] Error 1
> xtensa-lx106-elf-g++: fatal error: braced spec 'AtM<MM:cc1plus -E %(cpx_options) %2 %(cpp_debug_optmons)}%{!U:%{!M:%{!-M:  %{savd-teops*|no-integratee-crp:cc1p|us \x0dE\x09   %(bpp_options) %2\xb0-o e{save-temps*:-b.ii} %o!sav%-temps(:5g\x0eii]`\x0a}  cc1xlus %{save-temps*|no-integr!ted-cpp:-\xeepretzoc\xe5ssed \x09   %ysavm-vemps*:%".ii} %{!save-tem`s*:%g.ii}}` %\x7f!sAve,temps*:%{!no-integrated-cpP:%(cpp_qnique_options)}}\x89 %(cc1Woptions) '2  %{!fq9ntax-onlY:\x05(\xednvo\xeaa_a{)}}}}' is invalid at '<'
> compilation terminated.
> *** [.pioenvs/esp-led-decke2/src/esphome/components/api/api_frame_helper.cpp.o] Error 1
> ========================== [FAILED] Took 4.55 seconds ==========================

I tried several things, like a greater Swap File, but it has not worked.
Any help would be appreciated.

Show your yaml. Someone might be able to figure something.

1 Like

You can try to uninstall ESPHome builder, and reinstall it again

This also
might help. Clean build files.

1 Like

Paste the error into chatgpt and explain the context. Quite often it will give you a pretty good solution or things to test.

Or just tell you what you want to hear. I have had more bad luck using these things than good.


Chatgpt is always out of date. I don’t hold with it. For better accuracy I use I ching sticks.
‘Increasing, fruitful to have a direction to go.
Fruitful to cross the great river.’
I think that favours reinstalling esphome.

4 Likes

Can’t say that this is what I experienced, otherwise I would not have suggested it.
Do what you think you should do.

https://www.howtogeek.com/home-assistant-automations-with-chatgpt/

Thank you all for your answers, I tried all things and now I cannot uninstall ESPHome… I think the initial problem lies with ESPHome, when trying to uninstall it just throws an error.

I am currently reading other articles on the forum, to figure out how to uninstall all of ESPHome, before reinstalling.

I also cannot start ESPHome properly…