Skip to content

gh-75929: Fix configure function checks under -Werror - #161343

Merged
itamaro merged 3 commits into
python:mainfrom
vasiliyk:gh-75929-fchdir
Nov 4, 2026
Merged

itamaro merged 3 commits into
python:mainfrom
vasiliyk:gh-75929-fchdir

Conversation

@vasiliyk

@vasiliyk vasiliyk commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Replace the void *x=$1 probe in PY_CHECK_FUNC with (void)$1 so the checks no longer fail under -Werror -Wall.

Tested on macOS (clang), and Linux (GCC 14).
Fixes gh-75929.

cc @vstinner

@itamaro itamaro left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lg with news wording nits

thanks for the fix!

@itamaro itamaro added needs backport to 3.14 bugs and security fixes needs backport to 3.15 bugs and security fixes labels Nov 4, 2026
@itamaro
itamaro enabled auto-merge (squash) November 4, 2026 22:10
@itamaro
itamaro merged commit 341f80e into python:main Nov 4, 2026
55 checks passed
@miss-islington-app

Copy link
Copy Markdown

Thanks @vasiliyk for the PR, and @itamaro for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Sorry, @vasiliyk and @itamaro, I could not cleanly backport this to 3.15 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 341f80e81a185c48ebbb2c0115401edf99f59baa 3.15

@miss-islington-app

Copy link
Copy Markdown

Sorry, @vasiliyk and @itamaro, I could not cleanly backport this to 3.14 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 341f80e81a185c48ebbb2c0115401edf99f59baa 3.14

@itamaro

itamaro commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

hey @vasiliyk , do you want to look into taking care of the backports?

@vstinner

vstinner commented Nov 4, 2026

Copy link
Copy Markdown
Member

Post-merge review: the change LGTM :-) Thanks for the fix.

@bedevere-app

bedevere-app Bot commented Nov 5, 2026

Copy link
Copy Markdown

GH-161371 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Nov 5, 2026
@bedevere-app

bedevere-app Bot commented Nov 5, 2026

Copy link
Copy Markdown

GH-161372 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Nov 5, 2026
vstinner pushed a commit that referenced this pull request Nov 5, 2026
…H-161343) (#161371)

Use `(void)$1` in `PY_CHECK_FUNC` instead of declaring an unused
variable. The unused-variable warning caused configure to report
declared functions such as `fchdir` as missing.
(cherry picked from commit 341f80e)
vstinner pushed a commit that referenced this pull request Nov 5, 2026
…H-161343) (#161372)

Use `(void)$1` in `PY_CHECK_FUNC` instead of declaring an unused
variable. The unused-variable warning caused configure to report
declared functions such as `fchdir` as missing.
(cherry picked from commit 341f80e)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

configure fails to detect fchdir() using CFLAGS="-Werror -Wall"

3 participants