Skip to content
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

OS.h Defines for min and max break c++ compilation (IDFGH-14017) #14840

Closed
3 tasks done
kenozz-igs opened this issue Nov 6, 2024 · 3 comments
Closed
3 tasks done

OS.h Defines for min and max break c++ compilation (IDFGH-14017) #14840

kenozz-igs opened this issue Nov 6, 2024 · 3 comments
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Type: Bug bugs in IDF

Comments

@kenozz-igs
Copy link

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

IDF version.

v5.3.1-638-ga0f798cfc4

Operating System used.

macOS

How did you build your project?

VS Code IDE

If you are using Windows, please specify command line type.

None

What is the expected behavior?

C++ build successful when nimble is enabled.

What is the actual behavior?

Cannot build project due to defines for min and max. Release/5.2 builds OK, Release/5.3 does not. Defines for min and max in os.h in 5.3 are the issue. 5.2 had a commit 155931f to remove them but looks to have been re-introducted in 5.3 commit fd31133.

5.2 - https://github.com/espressif/esp-nimble/blob/e08302d66d77a29e65dffe2c336e4dcda4e80e51/porting/nimble/include/os/os.h

5.3 - https://github.com/espressif/esp-nimble/blob/32b2124f54238e70ecd4c72a753698babdd939f7/porting/nimble/include/os/os.h

Steps to reproduce.

Bulid C++ project with Nimble and compiler error is observed.

Build or installation Logs.

No response

More Information.

Looks to be same issue as in ticket

@kenozz-igs kenozz-igs added the Type: Bug bugs in IDF label Nov 6, 2024
@github-actions github-actions bot changed the title OS.h Defines for min and max break c++ compilation OS.h Defines for min and max break c++ compilation (IDFGH-14017) Nov 6, 2024
@espressif-bot espressif-bot added the Status: Opened Issue is new label Nov 6, 2024
@ESPAbhinav
Copy link
Collaborator

Hi @kenozz-igs ,
I have removed the header definition from the OS.h file, just like in v5.2. The following is the patch file for changes. Can you please confirm if the patch provided works for you?
remove_min_max_defs.zip

@kenozz-igs
Copy link
Author

Hi @ESPAbhinav thanks for the quick response. I can confirm the patch does resolve the build issue. Is there any plans to merge into the 5.3 release?

@ESPAbhinav
Copy link
Collaborator

Hi @kenozz-igs , already raised the MR to merge this change into release 5.3 .Thanks for identifying the issue.

@espressif-bot espressif-bot added Status: In Progress Work is in progress Status: Selected for Development Issue is selected for development and removed Status: Opened Issue is new Status: In Progress Work is in progress labels Nov 7, 2024
@espressif-bot espressif-bot added Status: Done Issue is done internally Resolution: NA Issue resolution is unavailable and removed Status: Selected for Development Issue is selected for development labels Nov 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Type: Bug bugs in IDF
Projects
None yet
Development

No branches or pull requests

3 participants