Skip to content

bpo-45723: Add macro for disabling/enabling CC warnings (GH-29466) - #29466

Merged
tiran merged 8 commits into
python:mainfrom
erlend-aasland:ac-cc-flags
Nov 8, 2021
Merged

bpo-45723: Add macro for disabling/enabling CC warnings (GH-29466)#29466
tiran merged 8 commits into
python:mainfrom
erlend-aasland:ac-cc-flags

Conversation

@erlend-aasland

@erlend-aaslanderlend-aasland commented Nov 8, 2021

Copy link
Copy Markdown
Contributor
  • Add PY_CHECK_CC_WARNING helper
  • Normalise variable name: ac_cv_[enable|disable]_[flag_name]_warning; for example ac_cv_disable_unused_result_warning
  • Use AS_IF to check results and add flags

No new cache vars added, so there is no speedups; only simplified ac code.

Bonus: fixed a misspelling bug (see ac_cv_enable_enable_strict_prototypes_warning)

https://bugs.python.org/issue45723

@erlend-aasland

Copy link
Copy Markdown
ContributorAuthor

cc. @tiran

Comment threadconfigure.ac Outdated
@erlend-aasland
erlend-aasland marked this pull request as ready for review November 8, 2021 10:47
Comment threadconfigure.ac Outdated
Comment threadconfigure.ac Outdated
Comment threadconfigure.ac Outdated
- Use AS_VAR_IF() a couple of more times
- Use CFLAGS iso. CC when overriding compiler flags
@tirantiran added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Nov 8, 2021
@bedevere-bot

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @tiran for commit 304f780 🤖

If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Nov 8, 2021
@erlend-aasland

Copy link
Copy Markdown
ContributorAuthor

Do you want a NEWS item for this, @tiran?

@tirantiran left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@erlend-aasland

Copy link
Copy Markdown
ContributorAuthor

Thanks for reviewing!

@tirantiran changed the title bpo-45723: Add macro for disabling/enabling CC warningsbpo-45723: Add macro for disabling/enabling CC warnings (GH-29466)Nov 8, 2021
@tiran
tiran merged commit 9bd0cf5 into python:mainNov 8, 2021
@erlend-aasland
erlend-aasland deleted the ac-cc-flags branch November 8, 2021 17:59
remykarem pushed a commit to remykarem/cpython that referenced this pull request Dec 7, 2021
Co-authored-by: Christian Heimes <christian@python.org>
remykarem pushed a commit to remykarem/cpython that referenced this pull request Jan 30, 2022
Co-authored-by: Christian Heimes <christian@python.org>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@erlend-aasland@bedevere-bot@tiran@the-knights-who-say-ni