Xtensa-esp32-elf-g++: error trying to exec 'cc1plus': execvp: No such file or directory

I'm having problems trying to run code on esp32 or esp8266. When I try and compile very basic code I get the above error message.

My computer is an old macbook air (2014) running big-sur

I have tried multiple re-installs of the Arduino 1.8 ide. I have
also tried deleting the ~/Library/Arduino15 directory but nothing seems to help.

I have switched verbose output on:

Arduino: 1.8.16 (Mac OS X), Board: "ESP32 Dev Module, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, None"

xtensa-esp32-elf-g++: error trying to exec 'cc1plus': execvp: No such file or directory
exit status 1
Error compiling for board ESP32 Dev Module.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.


Arduino: 1.8.16 (Mac OS X), Board: "ESP32 Dev Module, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, None"

/private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/arduino-builder -dump-prefs -logger=machine -hardware /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/hardware -hardware /Users/kevinwright/Library/Arduino15/packages -tools /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/tools-builder -tools /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/kevinwright/Library/Arduino15/packages -built-in-libraries /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/libraries -libraries /Users/kevinwright/Documents/Arduino/libraries -fqbn=esp32:esp32:esp32:PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=921600,DebugLevel=none -ide-version=10816 -build-path /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395 -warnings=none -build-cache /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_cache_417955 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.mkspiffs.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.mkspiffs-0.2.3.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.xtensa-esp32-elf-gcc.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0 -prefs=runtime.tools.xtensa-esp32-elf-gcc-1.22.0-97-gc752ad5-5.2.0.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0 -prefs=runtime.tools.esptool_py.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0 -prefs=runtime.tools.esptool_py-3.0.0.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0 -verbose /Users/kevinwright/Documents/Arduino/test_esp32/test_esp32.ino
/private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/arduino-builder -compile -logger=machine -hardware /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/hardware -hardware /Users/kevinwright/Library/Arduino15/packages -tools /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/tools-builder -tools /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/hardware/tools/avr -tools /Users/kevinwright/Library/Arduino15/packages -built-in-libraries /private/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/AppTranslocation/3B42CB54-6C3B-49D3-947A-BCF3A5D097E1/d/Arduino.app/Contents/Java/libraries -libraries /Users/kevinwright/Documents/Arduino/libraries -fqbn=esp32:esp32:esp32:PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=921600,DebugLevel=none -ide-version=10816 -build-path /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395 -warnings=none -build-cache /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_cache_417955 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.mkspiffs.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.mkspiffs-0.2.3.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.xtensa-esp32-elf-gcc.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0 -prefs=runtime.tools.xtensa-esp32-elf-gcc-1.22.0-97-gc752ad5-5.2.0.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0 -prefs=runtime.tools.esptool_py.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0 -prefs=runtime.tools.esptool_py-3.0.0.path=/Users/kevinwright/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0 -verbose /Users/kevinwright/Documents/Arduino/test_esp32/test_esp32.ino
Using board 'esp32' from platform in folder: /Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6
Using core 'esp32' from platform in folder: /Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6
bash -c "[ ! -f "/Users/kevinwright/Documents/Arduino/test_esp32"/partitions.csv ] || cp -f "/Users/kevinwright/Documents/Arduino/test_esp32"/partitions.csv "/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395"/partitions.csv"
bash -c "[ -f "/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395"/partitions.csv ] || cp "/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6"/tools/partitions/default.csv "/var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395"/partitions.csv"
Detecting libraries used...
/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0/bin/xtensa-esp32-elf-g++ -DESP_PLATFORM "-DMBEDTLS_CONFIG_FILE="mbedtls/esp_config.h"" -DHAVE_CONFIG_H -DGCC_NOT_5_2_0=0 -DWITH_POSIX -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/config -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/app_trace -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/app_update -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/asio -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/bootloader_support -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/bt -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/coap -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/console -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/driver -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/efuse -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-tls -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp32 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_adc_cal -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_event -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_http_client -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_http_server -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_https_ota -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_https_server -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_ringbuf -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_websocket_client -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/espcoredump -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/ethernet -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/expat -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/fatfs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/freemodbus -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/freertos -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/heap -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/idf_test -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/jsmn -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/json -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/libsodium -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/log -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/lwip -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mbedtls -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mdns -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/micro-ecc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mqtt -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/newlib -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/nghttp -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/nvs_flash -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/openssl -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/protobuf-c -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/protocomm -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/pthread -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/sdmmc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/smartconfig_ack -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/soc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/spi_flash -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/spiffs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/tcp_transport -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/tcpip_adapter -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/ulp -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/unity -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/vfs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wear_levelling -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wifi_provisioning -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wpa_supplicant -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/xtensa-debug-module -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-face -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp32-camera -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-face -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/fb_gfx -std=gnu++11 -Os -g3 -Wpointer-arith -fexceptions -fstack-protector -ffunction-sections -fdata-sections -fstrict-volatile-bitfields -mlongcalls -nostdlib -w -Wno-error=maybe-uninitialized -Wno-error=unused-function -Wno-error=unused-but-set-variable -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wno-unused-parameter -Wno-unused-but-set-parameter -Wno-missing-field-initializers -Wno-sign-compare -fno-rtti -c -w -x c++ -E -CC -DF_CPU=240000000L -DARDUINO=10816 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 "-DARDUINO_BOARD="ESP32_DEV"" "-DARDUINO_VARIANT="esp32"" -DESP32 -DCORE_DEBUG_LEVEL=0 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/cores/esp32 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/variants/esp32 /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395/sketch/test_esp32.ino.cpp -o /dev/null
Error while detecting libraries included by /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395/sketch/test_esp32.ino.cpp
Generating function prototypes...
/Users/kevinwright/Library/Arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-97-gc752ad5-5.2.0/bin/xtensa-esp32-elf-g++ -DESP_PLATFORM "-DMBEDTLS_CONFIG_FILE="mbedtls/esp_config.h"" -DHAVE_CONFIG_H -DGCC_NOT_5_2_0=0 -DWITH_POSIX -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/config -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/app_trace -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/app_update -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/asio -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/bootloader_support -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/bt -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/coap -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/console -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/driver -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/efuse -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-tls -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp32 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_adc_cal -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_event -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_http_client -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_http_server -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_https_ota -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_https_server -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_ringbuf -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp_websocket_client -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/espcoredump -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/ethernet -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/expat -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/fatfs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/freemodbus -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/freertos -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/heap -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/idf_test -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/jsmn -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/json -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/libsodium -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/log -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/lwip -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mbedtls -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mdns -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/micro-ecc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/mqtt -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/newlib -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/nghttp -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/nvs_flash -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/openssl -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/protobuf-c -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/protocomm -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/pthread -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/sdmmc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/smartconfig_ack -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/soc -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/spi_flash -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/spiffs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/tcp_transport -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/tcpip_adapter -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/ulp -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/unity -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/vfs -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wear_levelling -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wifi_provisioning -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/wpa_supplicant -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/xtensa-debug-module -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-face -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp32-camera -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/esp-face -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/sdk/include/fb_gfx -std=gnu++11 -Os -g3 -Wpointer-arith -fexceptions -fstack-protector -ffunction-sections -fdata-sections -fstrict-volatile-bitfields -mlongcalls -nostdlib -w -Wno-error=maybe-uninitialized -Wno-error=unused-function -Wno-error=unused-but-set-variable -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wno-unused-parameter -Wno-unused-but-set-parameter -Wno-missing-field-initializers -Wno-sign-compare -fno-rtti -c -w -x c++ -E -CC -DF_CPU=240000000L -DARDUINO=10816 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 "-DARDUINO_BOARD="ESP32_DEV"" "-DARDUINO_VARIANT="esp32"" -DESP32 -DCORE_DEBUG_LEVEL=0 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/cores/esp32 -I/Users/kevinwright/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/variants/esp32 /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395/sketch/test_esp32.ino.cpp -o /var/folders/jb/vg9zm62532q_xsymf9f32zp40000gp/T/arduino_build_981395/preproc/ctags_target_for_gcc_minus_e.cpp
xtensa-esp32-elf-g++: error trying to exec 'cc1plus': execvp: No such file or directory
exit status 1
Error compiling for board ESP32 Dev Module.

Can anybody help me?

For the ESP32, did you do this:

Add Boards Manager Entry

  1. Open the Arduino IDE. Make sure that you are at version 1.8 or higher, if not then update your IDE with the latest version.
  2. Click on the File menu on the top menu bar.
  3. Click on the Preferences menu item. This will open a Preferences dialog box.
  4. You should be on the Settings tab in the Preferences dialog box by default.
  5. Look for the textbox labeled “Additional Boards Manager URLs ”.
  6. If there is already text in this box add a coma at the end of it, then follow the next step.
  7. Paste the following link into the text box – https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
  8. Click the OK button to save the setting.
    ?

From: Getting Started with the ESP32 - Using the Arduino IDE (dronebotworkshop.com)

1 Like

Hi,

My additional boards already had a couple of entries for the esp32 and esp8266. I tried replacing those with the url you provided. Then I restarted the ide. Unfortunately it didn't make any difference. Its worth mentioning that the adding the boards process did not go smoothly and hung several times which I had to cancel and retry.