PlatformIO Community

ESP32 CLion Platformio integration failing to rebuild index

Hi, i was trying to migrate from Arduino IDE to CLion.
First i was doing every step from the instruction, but couldn’t get things started. Once i started playing around with some buttons (i am new to CLion, since my main languages are C# and Java) - somehow i got it to build and even upload to the board.

However everything is highlighted in red in the code. I read about the need to rebuild the indexes, however i get this error:

Error
"C:\Program Files\JetBrains\CLion 2019.3.2\bin\cmake\win\bin\cmake.exe" -DCMAKE_BUILD_TYPE=esp32dev -G "CodeBlocks - NMake Makefiles" C:\ESPProjects\***
-- Configuring done
-- Generating done
-- Build files have been written to: C:/ESPProjects/***/cmake-build-esp32dev

Cannot get compiler information:
	Compiler exited with error code 1: C:\Users\User\.platformio\packages\toolchain-xtensa32\bin\xtensa-esp32-elf-g++.exe @C:\Users\User\AppData\Local\Temp\response-file1828945137723025101 C:\Users\User\AppData\Local\Temp\compiler-file6154558047776335844 | @response-file1828945137723025101=/TP -IC:\ESPProjects\***\include -IC:\ESPProjects\***\src -IC:\ESPProjects\***\lib\uBlox -IC:\ESPProjects\***\lib\Web -IC:\ESPProjects\***\lib\NeoGPS\src -IC:\ESPProjects\***\lib\ESPAsyncWebServer-master\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\WiFi\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\FS\src -IC:\ESPProjects\***\lib\AsyncTCP-master\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\config -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\app_trace -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\app_update -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\asio -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\bootloader_support -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\bt -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\coap -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\console -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\driver -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp-tls -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp32 -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_adc_cal -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_event -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_http_client -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_http_server -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_https_ota -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp_ringbuf -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\ethernet -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\expat -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\fatfs -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\freemodbus -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\freertos -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\heap -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\idf_test -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\jsmn -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\json -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\libsodium -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\log -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\lwip -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\mbedtls -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\mdns -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\micro-ecc -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\mqtt -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\newlib -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\nghttp -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\nvs_flash -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\openssl -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\protobuf-c -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\protocomm -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\pthread -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\sdmmc -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\smartconfig_ack -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\soc -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\spi_flash -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\spiffs -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\tcp_transport -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\tcpip_adapter -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\ulp -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\vfs -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\wear_levelling -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\wifi_provisioning -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\wpa_supplicant -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\xtensa-debug-module -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp-face -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\esp32-camera -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\tools\sdk\include\fb_gfx -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\cores\esp32 -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\variants\esp32 -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\ArduinoOTA\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\AsyncUDP\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\AzureIoT\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\BLE\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\BluetoothSerial\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\DNSServer\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\EEPROM\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\ESP32\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\ESPmDNS\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\FFat\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\HTTPClient\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\HTTPUpdate\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\NetBIOS\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\Preferences\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\SD\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\SD_MMC\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\SPI\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\SPIFFS\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\SimpleBLE\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\Ticker\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\Update\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\WebServer\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\WiFiClientSecure\src -IC:\Users\User\.platformio\packages\framework-arduinoespressif32\libraries\Wire\src -IC:\Users\User\.platformio\packages\toolchain-xtensa32\xtensa-esp32-elf\include -IC:\Users\User\.platformio\packages\toolchain-xtensa32\xtensa-esp32-elf\include\c++\5.2.0 -IC:\Users\User\.platformio\packages\toolchain-xtensa32\xtensa-esp32-elf\include\c++\5.2.0\xtensa-esp32-elf -IC:\Users\User\.platformio\packages\toolchain-xtensa32\lib\gcc\xtensa-esp32-elf\5.2.0\include -IC:\Users\User\.platformio\packages\toolchain-xtensa32\lib\gcc\xtensa-esp32-elf\5.2.0\include-fixed -IC:\Users\User\.platformio\packages\tool-unity /DWIN32 /D_WINDOWS /W3 /GR /EHsc "-D'PLATFORMIO=40100'" "-D'ARDUINO_ESP32_DEV'" "-D'ESP32'" "-D'ESP_PLATFORM'" "-D'F_CPU=240000000L'" "-D'HAVE_CONFIG_H'" "-D'MBEDTLS_CONFIG_FILE=mbedtls/esp_config.h'" "-D'ARDUINO=10805'" "-D'ARDUINO_ARCH_ESP32'" "-D'ARDUINO_VARIANT=esp32'" "-D'ARDUINO_BOARD=Espressif ESP32 Dev Module'" /Be /Bd /EP
	xtensa-esp32-elf-g++.exe: error: /TP: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /DWIN32: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /D_WINDOWS: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /W3: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /GR: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /EHsc: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /Be: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /Bd: No such file or directory
	xtensa-esp32-elf-g++.exe: error: /EP: No such file or directory
	
	

[Failed to reload]