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

compiler/clang: ignore main-return-type warning for clang #54525

Merged

Conversation

keith-packard
Copy link
Collaborator

@keith-packard keith-packard commented Feb 7, 2023

Unlike gcc, clang splits out the flag controlling warnings about the return type of `main' from other warnings related to that function. Add the extra -Wno-main-return-type flag to mask these warnings when building Zephyr without -ffreestanding, as when using picolibc.

Signed-off-by: Keith Packard [email protected]

(Partially) fixes #54336

Unlike gcc, clang splits out the flag controlling warnings about the return
type of `main' from other warnings related to that function. Add the extra
-Wno-main-return-type flag to mask these warnings when building Zephyr
without -ffreestanding, as when using picolibc.

Signed-off-by: Keith Packard <[email protected]>
@keith-packard
Copy link
Collaborator Author

Note that this patch is not required once the return type from main is set to int, so this patch should not be merged if #54628 gets merged.

@fabiobaltieri fabiobaltieri merged commit 0f692f5 into zephyrproject-rtos:main Feb 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

picolibc is incompatible with xcc / xcc-clang toolchains
7 participants