-
Notifications
You must be signed in to change notification settings - Fork 7.4k
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
How to disable esp-idf 5.0-rc1 -Werror=all flag (IDFGH-8780) #10212
Comments
@stkw0 -Werror=all has been used in IDF for a very long time. For example, here it is in release v3.3. So there hasn't been any recent change regarding this flag.
Thank you for noticing. Have fixed the link. |
Then I guess the problem is in some other place. What I can say is that the same code compiles correctly with 5.0-beta1 but not with 5.0-rc1. If needed I can provide a small test case |
I modified the hello_world example to demonstrate the issue. Seems it only happens when a component is added. |
You are running into #9511. Please take a look at https://docs.espressif.com/projects/esp-idf/en/v5.0-rc1/esp32/migration-guides/release-5.x/gcc.html#int32-t-and-uint32-t-for-xtensa-compiler for the instructions to migrate your code or work around this warning. |
The interesting thing is that the GCC version didn't change between 5.0-beta1 and 5.0-rc1, it's the same, 11.2.0. Also the implicit conversion from a C++ enum class to int that was possible with 5.0-beta1 is not possible anymore with 5.0-rc1. That's what made me think about the -Werror flag, in fact removing it produces the same behavior than with 5.0-beta1. |
Correct, the version is the same in these releases. However the toolchain build we had in v5.0-beta1 was still configured with uint32_t == unsigned int. The newer toolchain build in v5.0-rc1 has uint32_t == unsigned long. The format string type warning for unsigned long != unsigned int mismatch is produced also in the earlier versions of GCC, so that part didn't change. |
I see,that makes sense, thank you very much. |
Hi, I also have problems when compiling a custom module on my project under Eclipse, where compilation fails because -Werror=all is set. Note that my issue has nothing to do with #9511 , I just want to disable the Werror=all flag. ESP-IDV v5.1.5 because newer versions are n ot compatible with the Arduino library. |
Answers checklist.
General issue report
I updated to esp-idf 5.0-rc1 and I saw that in this last version -Werror=all is enabled. This caused some compilation errors (in our code) that before were treated as warnings. How can this flag be removed? I tried adding "-Wno-error" and "-Wno-error=all" without success. I know that I could manually add -Wno-error= for each type of errors but I would want to avoid this.
I thought that, being this an RC, maybe this was added for testing and wasn't removed later. Was this added on purpose?
BTW the migration guide link on 5.0-rc1 release is broken, it returns a 404
The text was updated successfully, but these errors were encountered: