[Python-checkins] [3.11] gh-99086: Fix implicit int compiler warning in configure check for PTHREAD_SCOPE_SYSTEM (GH-99085) (#99118)

erlend-aasland webhook-mailer at python.org
Sat Nov 5 05:27:59 EDT 2022


https://github.com/python/cpython/commit/573b4518867a3cb3c82aa0edd8e86b073e9ff6da
commit: 573b4518867a3cb3c82aa0edd8e86b073e9ff6da
branch: 3.11
author: Erlend E. Aasland <erlend.aasland at protonmail.com>
committer: erlend-aasland <erlend.aasland at protonmail.com>
date: 2022-11-05T10:27:47+01:00
summary:

[3.11] gh-99086: Fix implicit int compiler warning in configure check for PTHREAD_SCOPE_SYSTEM (GH-99085) (#99118)

(cherry picked from commit 12078e78f6e4a21f344e4eaff529e1ff3b97734f)

Co-authored-by: Sam James <sam at cmpct.info>

files:
A Misc/NEWS.d/next/Build/2022-11-04-02-58-10.gh-issue-99086.DV_4Br.rst
M configure
M configure.ac

diff --git a/Misc/NEWS.d/next/Build/2022-11-04-02-58-10.gh-issue-99086.DV_4Br.rst b/Misc/NEWS.d/next/Build/2022-11-04-02-58-10.gh-issue-99086.DV_4Br.rst
new file mode 100644
index 000000000000..e320ecfdfbb7
--- /dev/null
+++ b/Misc/NEWS.d/next/Build/2022-11-04-02-58-10.gh-issue-99086.DV_4Br.rst
@@ -0,0 +1 @@
+Fix ``-Wimplicit-int`` compiler warning in :program:`configure` check for ``PTHREAD_SCOPE_SYSTEM``.
diff --git a/configure b/configure
index a150b7767d02..2d5be29abf17 100755
--- a/configure
+++ b/configure
@@ -14454,7 +14454,7 @@ else
       void *foo(void *parm) {
         return NULL;
       }
-      main() {
+      int main() {
         pthread_attr_t attr;
         pthread_t id;
         if (pthread_attr_init(&attr)) return (-1);
diff --git a/configure.ac b/configure.ac
index 79dc1f159a1b..2cce5fe008d2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4172,7 +4172,7 @@ if test "$posix_threads" = "yes"; then
       void *foo(void *parm) {
         return NULL;
       }
-      main() {
+      int main() {
         pthread_attr_t attr;
         pthread_t id;
         if (pthread_attr_init(&attr)) return (-1);



More information about the Python-checkins mailing list