Page MenuHomePhabricator

clang: Exclude efi_main from -Wmissing-prototypes

Authored by DaanDeMeyer on Jan 30 2021, 11:31 AM.


Group Reviewers
Restricted Project
rG7dd42ecfa2a2: clang: Exclude efi_main from -Wmissing-prototypes

When compiling UEFI applications, the main function is named
efi_main() instead of main(). Let's exclude efi_main() from
-Wmissing-prototypes as well to avoid warnings when working
on UEFI applications.

Diff Detail

Event Timeline

DaanDeMeyer requested review of this revision.Jan 30 2021, 11:31 AM
DaanDeMeyer created this revision.

CI failures seem unrelated?

Please include test coverage

Added a test

dblaikie accepted this revision.Feb 19 2021, 7:33 PM

Looks good to me - maybe the test could be rolled into whatever file is already testing -Wmissing-prototype and the existing special case for "main"?

Do you need me to commit this, or can you commit it yourself?

This revision is now accepted and ready to land.Feb 19 2021, 7:33 PM

Moved the test into the no-warn-missing-prototype test as requested.

DaanDeMeyer added a comment.EditedFeb 20 2021, 12:00 PM

I should be able to commit it myself. Thanks for the review!

dblaikie accepted this revision.Feb 20 2021, 12:00 PM

Reaffirming approval with the test change - looks great!

This revision was landed with ongoing or failed builds.Feb 20 2021, 12:04 PM
This revision was automatically updated to reflect the committed changes.