Skip to content

Make curses compiling on NetBSD 7.1 and tests passing #76072

Description

@serhiy-storchaka
BPO 31891
Nosy @Yhg1s, @serhiy-storchaka
PRs
  • bpo-31891: Fix building the curses module on NetBSD. #4165
  • [3.6] bpo-31891: Fix building the curses module on NetBSD. (GH-4165) #4189
  • [2.7] bpo-31891: Fix building the curses module on NetBSD. (GH-4165). #4194
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/serhiy-storchaka'
    closed_at = <Date 2017-10-31.20:04:32.857>
    created_at = <Date 2017-10-29.09:21:28.184>
    labels = ['extension-modules', 'build', '3.7']
    title = 'Make curses compiling on NetBSD 7.1 and tests passing'
    updated_at = <Date 2017-10-31.20:04:32.857>
    user = 'https://github.com/serhiy-storchaka'

    bugs.python.org fields:

    activity = <Date 2017-10-31.20:04:32.857>
    actor = 'serhiy.storchaka'
    assignee = 'serhiy.storchaka'
    closed = True
    closed_date = <Date 2017-10-31.20:04:32.857>
    closer = 'serhiy.storchaka'
    components = ['Extension Modules']
    creation = <Date 2017-10-29.09:21:28.184>
    creator = 'serhiy.storchaka'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 31891
    keywords = ['patch']
    message_count = 4.0
    messages = ['305180', '305289', '305293', '305299']
    nosy_count = 2.0
    nosy_names = ['twouters', 'serhiy.storchaka']
    pr_nums = ['4165', '4189', '4194']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'compile error'
    url = 'https://bugs.python.org/issue31891'
    versions = ['Python 2.7', 'Python 3.6', 'Python 3.7']

    Activity

    1. serhiy-storchaka commented on Oct 29, 2017

      @serhiy-storchaka
      MemberAuthor

      NetBSD perhaps is the last open OS that don't use ncurses. For now the _curses module is not compiled on NetBSD. Its curses implementation doesn't contain several ncurses functions. <term.h> included for non-ncurses implementations defines a couple of macros that conflict with local variable names. The hardcoded signature of setupterm differs from the signature in <term.h>. The fallback implementation of has_key() depends on KEY_* constants that are absent in NetBSD curses too. It seems to me that curses is broken on NetBSD for very long time.

      The proposed PR fixes building of the _curses module and makes curses tests passing. This of course doesn't guaranties that curses works correctly on NetBSD, our curses tests are rudimentary.

      There were other NetBSD specific guards in the code. They are no longer needed because the guarded functions already are supported in NetBSD for long time. There are bpo-9667 and bpo-21457 for removing unneeded conditional compilation.

    2. serhiy-storchaka commented on Oct 31, 2017

      @serhiy-storchaka
      MemberAuthor

      New changeset baac01e by Serhiy Storchaka in branch 'master':
      bpo-31891: Fix building the curses module on NetBSD. (bpo-4165)
      baac01e

    3. serhiy-storchaka commented on Oct 31, 2017

      @serhiy-storchaka
      MemberAuthor

      New changeset 5db3208 by Serhiy Storchaka (Miss Islington (bot)) in branch '3.6':
      bpo-31891: Fix building the curses module on NetBSD. (GH-4165) (bpo-4189)
      5db3208

    4. serhiy-storchaka commented on Oct 31, 2017

      @serhiy-storchaka
      MemberAuthor

      New changeset e0fc1af by Serhiy Storchaka in branch '2.7':
      [2.7] bpo-31891: Fix building the curses module on NetBSD. (GH-4165). (bpo-4194)
      e0fc1af

    5. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Labels

    3.7 (EOL)end of lifebuildThe build process and cross-buildextension-modulesC modules in the Modules dir

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions