-
-
Notifications
You must be signed in to change notification settings - Fork 638
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ESP32S3 using very old toolchain #1435
Comments
I also have an environment that targets both arduino and esp-idf, which fails with this error:
|
It is not possible to freely choose the toolchain version. |
I understand. But then something must have changed in the package, because this was working fine a week ago - I'm building from a known good commit hash. |
Hi @m-mcgowan, unfortunately, the toolchain version is tightly coupled to the framework version, so you cannot change it arbitrarily. |
I feel there's a miscommunication here and that this issue should be kept open. My build was working fine a week ago, with nothing unusual in the I have an environment for compiling the code for the arduino framework, and another environment that targets arduino and esp-idf. Both of these had been working fine, with C++23 support, but no longer do so. If I knew how to pin the versions of the packages/frameworks to what being selected as default prior to last week that would most likely provide a suitable workaround. I have found a workaround that doesn't involve pinning versions, which, although far less than ideal, I am happy to share, but I feel this should be addressed at the source, either in this package, or in the espressif Arduino IDF component dependency, or whereever the fix is required. Notwithstanding that, at the very least, I would appreciate some help getting back to a reliable build by pinning versions of frameworks/packages. I am not very familiar with the inner workings of the PIO frameworks, packages and toolchains, and despite my research of the changes in the past week I was not able to find a solution. I am working on a project that has been in development for several months, for which I advocated PlatformIO. My workaround can support continued development, but I will not be able to release the software later this year with that workaround.
To be clear, I was not choosing the toolchain version and was just using the latest, which had C++23 (gnu++2b) support. I would truly appreciate some help from anyone that knows the PIO ecosystem better than I do. |
@m-mcgowan please share here your entire |
My trouble.
|
@brightproject Dont hijack this issue with something unrelated. |
I believe this is the same problem. The old toolchain is now being used, where it wasn't previously. |
Here's a minimal example:
The esp32s3 environment used to work shortly before I opened this issue. The project relies on concepts, so the minimal source to test is
The esp32 environment, which used to compile, now fails with
Changing to gnu++2a removes the unrecognized option error, but the concepts header is not present in that version of the toolchain.
So, the newer toolchain was being used by default previously, but for some reason has reverted to a much older version without gnu++2b and concepts support. The esp32s3_working environment is my workaround, which does compile. Although many warnings are generated:
The firmware built works as expected despite the compiler and linker warnings. |
If you want/need pin the platform version. This will use any version found on the system
better do like this (using latest version)
|
@m-mcgowan please share also the beginning of the log where the configuration header is printed for the broken env |
Thank you for that suggestion. I did try pinning the platform version, but couldn't return to the previous behavior using any of the released versions. I know this sounds crazy! That's why I'm so puzzled about what has changed. |
Here's fuller logs from the build: With the old toolchain:
With the new toolchain:
|
@m-mcgowan To use |
@m-mcgowan The default and recommended toolchain for the Arduino framework is v8.4.0 and it's NOT capable of compiling projects with |
Thank you, I understand that. The point here is that I didn't need any custom overrides or any changes to a simple platformio environment, and was able to target the code for g++2b. It had been working fine up until recently. In practice, I have several environments, one targeting just arduino and the other a combination of arduino and esp-idf. Both of these were working (with no toolchain overrides) up until the time I opened this issue. The overrides are merely a workaround so that I'm not blocked until the underlying cause is resolved. |
I can appreciate this may not be a PlatformIO issue, and could well lie with the arduino core for esp32s3. I can open an issue in the core. What is puzzling me is that this WAS working perfectly, with no custom overrides, no compiler or linker warnings, but then suddenly stopped working shortly before I opened this issue. I looked through the recent PIO changes and there were some changes in the espressif package around selecting the arduino toolchain, overriding versions etc. I will try pinning version numbers to see if I can get back to the state that was working previously, which hopefully will shed some light on what has changed. |
The latest version of There is no newer version in the registry, so at the moment you're stuck. |
So puzzling that this has worked previously. But you're definitely onto something - when I installed the esp32 BSP in Arduino IDE, version 3.0.4, it does use the correct toolchains:
Full log below. So who's chain (no pun intended) do I have to pull to get 3.0.4 updated in the platformIO registry? I'd be happy to help, if someone were to show me the ropes.
|
see #1225 |
+1 for needing a newer version toolchain. The current |
Use this instead: |
Thank you for pointing me to this, and a thank you to the project's maintainers. This is perfect! |
So, what is really strange, is that the project is now building again as it was a few weeks back. With the same platformio.ini as above, the default espressif32 package is now using the correct compiler versions.
Build output
It's great that it's suddenly working again, but my fear is that it will suddenly stop working. I'm so confused! :-) |
Do you have a I was using platform version 6.6.0, |
But There must be some leftovers on your system. Maybe you have used
or pioarduino before? |
I hadn't used pioarduino before until today, and it's probably no coincidence that things started working after that. It looks like platformio is picking up the different platform than intended? There is no I don't recognize the To try to remove any leftovers, I removed Thank you for these responses, I feel now there is at least some explanation of what is going on. I have saved the deleted folders from |
The key is |
If I specify the platform like this
Then the code build is
If I specify the platform like this
Then the code build is
That's why I often just specify it to get the latest version of the framework:
|
I have a PlatformIO project that I've been working on for several weeks. It's been working fine, but last week (around 1st August) the project stopped compiling.
This is the relevant part of platformio.ini
When building, the toolchain selected is an old version:
I have tried uninstalling and reinstalling the latest version of
toolchain-xtensa-esp32s3
but the PIO build continues to use the old version.Running
pio pkg update
shows that all dependencies are already up to date.I added
which then uses the latest version of the toolchain (
[email protected]+20230208
), and does build the .elf file, but results in many warnings like:and during linking,
I've also deleted the ~/.platformio directory and the project's
.pio
directory but no change in behavior.The text was updated successfully, but these errors were encountered: