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.

Title: _cursesmodule.c fails with ncurses-5.9 on Linux
Type: compile error Stage: resolved
Components: Extension Modules Versions: Python 3.7, Python 3.6, Python 2.7
Status: closed Resolution: duplicate
Dependencies: Superseder: Fix curses module compilation with ncurses6
View: 25720
Assigned To: Nosy List: devurandom, masamoto, phaering, rpetrov, serhiy.storchaka, vstinner
Priority: normal Keywords: patch

Created on 2012-04-16 16:30 by phaering, last changed 2022-04-11 14:57 by admin. This issue is now closed.

File name Uploaded Description Edit
0001-CROSS-properly-detect-WINDOW-_flags-for-different-nc.patch rpetrov, 2012-04-16 16:59
3.4-issue14598-curses-WINDOW_flags.patch masamoto, 2015-04-17 04:00 review
Messages (7)
msg158481 - (view) Author: Peter Häring (phaering) Date: 2012-04-16 16:30
I need to define NCURSES_INTERNALS in py_curses.h before ncurses.h is included, even on my Linux system with ncurses-5.9.

See the same issue for cygwin: 14438
msg158484 - (view) Author: Roumen Petrov (rpetrov) * Date: 2012-04-16 16:52
you could find how to resolve in last patch attached to issue 3754
msg158485 - (view) Author: Roumen Petrov (rpetrov) * Date: 2012-04-16 16:59
extracted as separate patch
msg158601 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2012-04-18 11:13
You should remove the old code instead of comment it.

+/* NOTE configure check if ncurses require such definition

+/* NOTE configure check for existence of flags
+ * Also flags are visible only if WINDOW structure is not opaque
msg241308 - (view) Author: Masayuki Yamamoto (masamoto) * Date: 2015-04-17 04:00
I rewrote the patch for Python 3.4.
The configure and were generated by autoreconf.

If evaluate to the curses WINDOW doesn't have the _flags member,
The configure script defines related macros and checks the member again.
And removed the quick-fix on py_curses header.  The quick-fix wouldn't be needed.

My environment (Cygwin 1.7.35 i686) cannot check the build case that NCURSES_OPAQUE is defined zero.
msg305375 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-11-01 12:44
Is this issue superseded by issue25720?
msg305392 - (view) Author: Masayuki Yamamoto (masamoto) * Date: 2017-11-01 18:57
Probably, yes.  ncurses on Cygwin has provided is_pad() [*]. In addition, the old version of Cygwin will become to not define WINDOW_HAS_FLAGS by issue25720.

[*] newer version than patchlevel 20090906 was provided on Cygwin in 2009.
Date User Action Args
2022-04-11 14:57:29adminsetgithub: 58803
2017-11-04 08:56:20serhiy.storchakasetstatus: open -> closed
superseder: Fix curses module compilation with ncurses6
resolution: duplicate
stage: resolved
2017-11-01 18:57:32masamotosetstatus: pending -> open

messages: + msg305392
2017-11-01 12:44:14serhiy.storchakasetstatus: open -> pending
versions: + Python 3.6, Python 3.7, - Python 3.4, Python 3.5
nosy: + serhiy.storchaka

messages: + msg305375
2015-04-17 04:00:24masamotosetfiles: + 3.4-issue14598-curses-WINDOW_flags.patch
versions: + Python 3.4, Python 3.5
nosy: + masamoto

messages: + msg241308
2012-10-17 08:47:22devurandomsetnosy: + devurandom
2012-04-18 11:13:14vstinnersetnosy: + vstinner
messages: + msg158601
2012-04-16 16:59:03rpetrovsetfiles: + 0001-CROSS-properly-detect-WINDOW-_flags-for-different-nc.patch
keywords: + patch
messages: + msg158485
2012-04-16 16:52:57rpetrovsetnosy: + rpetrov
messages: + msg158484
2012-04-16 16:30:53phaeringcreate