This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: --without-threads build fails due to undeclared _PyGILState_check_enabled
Type: behavior Stage: resolved
Components: Build Versions: Python 3.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Alex.Willmer, berker.peksag, python-dev, vstinner
Priority: normal Keywords: patch

Created on 2016-06-16 17:37 by Alex.Willmer, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
without-threads.build.log Alex.Willmer, 2016-06-16 17:37
issue27336.diff berker.peksag, 2016-06-16 19:14 review
Messages (7)
msg268683 - (view) Author: Alex Willmer (Alex.Willmer) * Date: 2016-06-16 17:37
Building current tip (rev 102062:3d726dbfca31), on Ubuntu 16.04/x86_64, using --without-thread fails; with the following error
gcc -c -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes    -Werror=declaration-after-statement   -I. -IInclude -I./Include    -DPy_BUILD_CORE -o Python/pylifecycle.o Python/pylifecycle.c
Python/pylifecycle.c: In function ‘Py_NewInterpreter’:
Python/pylifecycle.c:751:5: error: ‘_PyGILState_check_enabled’ undeclared (first use in this function)
     _PyGILState_check_enabled = 0;
     ^
Python/pylifecycle.c:751:5: note: each undeclared identifier is reported only once for each function it appears in
Makefile:1575: recipe for target 'Python/pylifecycle.o' failed
make: *** [Python/pylifecycle.o] Error 1

I've attached the full build log.
msg268690 - (view) Author: Berker Peksag (berker.peksag) * (Python committer) Date: 2016-06-16 19:14
The attached patch should fix this.
msg268694 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2016-06-16 20:53
@Alex Willmer: Why do you build Python without threads?
msg268695 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2016-06-16 20:54
issue27336.diff LGTM with a minor comment on the review.
msg268716 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-06-17 10:24
New changeset 2baaf7e31b13 by Berker Peksag in branch 'default':
Issue #27336: Fix compilation failures --without-threads
https://hg.python.org/cpython/rev/2baaf7e31b13
msg268717 - (view) Author: Berker Peksag (berker.peksag) * (Python committer) Date: 2016-06-17 10:25
Thanks for the report.
msg268718 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-06-17 10:29
New changeset cbe977fd306f by Victor Stinner in branch 'default':
Issue #27336: Fix compilation on Windows
https://hg.python.org/cpython/rev/cbe977fd306f
History
Date User Action Args
2022-04-11 14:58:32adminsetgithub: 71523
2016-06-17 10:29:49python-devsetmessages: + msg268718
2016-06-17 10:25:04berker.peksagsetstatus: open -> closed
resolution: fixed
messages: + msg268717

stage: patch review -> resolved
2016-06-17 10:24:28python-devsetnosy: + python-dev
messages: + msg268716
2016-06-16 20:54:18vstinnersetmessages: + msg268695
2016-06-16 20:53:57vstinnersetmessages: + msg268694
2016-06-16 19:14:58berker.peksagsetfiles: + issue27336.diff

nosy: + berker.peksag
messages: + msg268690

keywords: + patch
2016-06-16 19:14:30berker.peksagsetnosy: + vstinner

type: behavior
stage: patch review
2016-06-16 17:37:44Alex.Willmercreate