Could not install ‘toolchain-xtensa32

Anybody else who also got this issue? It occurred when installing latest vscode and pio. There was an old post about this bug which was solved almost two years ago.

PIO Core Call Error: "The current working directory C:\Users\59146\Documents\PlatformIO\Projects\test will be used for the project.

The next files/directories have been created in C:\Users\59146\Documents\PlatformIO\Projects\test
include - Put project header files here
lib - Put here project specific (private) libraries
src - Put project source files here
platformio.ini - Project Configuration File
\n\nError: Could not install ‘toolchain-xtensa32’ with version requirements ‘~2.50200.0’ for your system ‘windows_amd64’.

Please try this solution → http://bit.ly/faq-package-manager "

An old installation on my laptop which worked fine is also having a similar issue, when setting up a project.

PIO Core Call Error: “The current working directory D:\PlatformIO\Projects\pioCLI_esp32_test will be used for the project.\n\r\nThe next files/directories have been created in D:\PlatformIO\Projects\pioCLI_esp32_test\ninclude - Put project header files here\nlib - Put here project specific (private) libraries\nsrc - Put project source files here\nplatformio.ini - Project Configuration File\n\n\nError: Could not install ‘framework-arduinoespressif32’ with version requirements ‘~2.10004.191002’ for your system ‘windows_amd64’.\n\nPlease try this solution → Redirecting...

Has espressif’s toochain been renamed from xtensa32 to arduinoespressif32?

What’s the contents of your platformio.ini?

I just ran the update process on my machine, and it says I’ve got that version of that particular package… which is the arduino board support / framework files for the ESP32… I then deleted the folder, and tried to compile an Arduino ESP32 project, and it was re-downloaded… so it seems to be working… this was on Windows, on a x64 machine, so it should be trying to download the windows_amd64 variant of any of those files also.

Platform Espressif 32
--------
Updating espressif32                     @ 1.11.0         [Up-to-date]
Updating tool-esptoolpy                  @ 1.20600.0      [Up-to-date]
Updating toolchain-xtensa32              @ 2.50200.80     [Up-to-date]
Updating framework-arduinoespressif32    @ 2.10004.191002 [Up-to-date]
Updating framework-espidf                @ 3.30300.190916 [Up-to-date]
Updating tool-mkspiffs                   @ 2.230.0        [Up-to-date]

In a pinch, you could try following the instructions linked at the end of that error message, and install that package (http://dl.platformio.org/packages/framework-arduinoespressif32-2.10004.191002.tar.gz) manually via the forth method documented. However, it would be better to find out why it isn’t working… perhaps antivirus or firewall settings are preventing PIO from downloading it? What happens if you run pio platform install espressif32 from a terminal? I get :slight_smile:

E:\Projects\PlatformIO\ESP32\CameraWebServer>pio platform install espressif32
PlatformManager: Installing espressif32
espressif32 @ 1.11.0 is already installed
PackageManager: Installing toolchain-xtensa32 @ ~2.50200.0
toolchain-xtensa32 @ 2.50200.80 is already installed
PackageManager: Installing tool-esptoolpy @ ~1.20600.0
tool-esptoolpy @ 1.20600.0 is already installed
The platform 'espressif32' has been successfully installed!
The rest of packages will be installed automatically depending on your build environment.

Thanks a lot for your help.

I suspect it’s due to my internet connection which is unstable downloading from sites like github. Will try again to see how it goes.

Just to confirm that the problem was indeed my internet connection. After changing internet connection, pio update went through without any issues and projects were set up successfully from pio home.

Thanks again!

1 Like

Oh, lovely… glad it’s working ok for you now! Happy coding! :slight_smile:

I am trying to get the toolchain to work on ARM (Raspberry Pi), for that I am trying to get the package from here Service End for Bintray, JCenter, GoCenter, and ChartCenter | JFrog (from this conversation)
I have downloaded and unzipped the file in the ~/.platformio/packages/toolchain-xtensa32
But when I run pio platform install espressif32 from the terminal, it keeps trying to download and install the package from the internet, rather than using the package I’ve put in the folder myself!
How to tell the linker to use the custom package instead?

After you have put the file there you shouldn’t need to manually install the compiler again, it should just be recognized.

You should first try and install the whole platform though and then you can override the compiler / toolchain.

More generically you can override any package with a custom package as shown in the docs, so e.g.

platform_packages = 
    toolchain-xtensa32@https://bintray.com/tsathishkumar/toolchain-xtensa32/download_file?file_path=toolchain-xtensa32-linux_armv7l-2.50200.80.tar.gz

in the platformio.ini of the project.

Thank you so much, it worked!
This is what my platformio.ini looks like:

[env:featheresp32dev]
platform_packages = toolchain-xtensa32@https://bintray.com/tsathishkumar/toolchain-xtensa32/download_file?file_path=toolchain-xtensa32-linux_armv7l-2.50200.80.tar.gz
platform = https://github.com/platformio/platform-espressif32.git
board = featheresp32
framework = arduino