mirror of
https://github.com/python/cpython.git
synced 2025-08-30 21:48:47 +00:00
bpo-42161: Modules/ uses _PyLong_GetZero() and _PyLong_GetOne() (GH-22998)
Use _PyLong_GetZero() and _PyLong_GetOne() in Modules/ directory. _cursesmodule.c and zoneinfo.c are now built with Py_BUILD_CORE_MODULE macro defined.
This commit is contained in:
parent
a6879d9445
commit
37834136d0
14 changed files with 57 additions and 36 deletions
5
setup.py
5
setup.py
|
@ -856,7 +856,8 @@ class PyBuildExt(build_ext):
|
|||
libraries=['m'],
|
||||
extra_compile_args=['-DPy_BUILD_CORE_MODULE']))
|
||||
# zoneinfo module
|
||||
self.add(Extension('_zoneinfo', ['_zoneinfo.c'])),
|
||||
self.add(Extension('_zoneinfo', ['_zoneinfo.c'],
|
||||
extra_compile_args=['-DPy_BUILD_CORE_MODULE']))
|
||||
# random number generator implemented in C
|
||||
self.add(Extension("_random", ["_randommodule.c"],
|
||||
extra_compile_args=['-DPy_BUILD_CORE_MODULE']))
|
||||
|
@ -1094,6 +1095,7 @@ class PyBuildExt(build_ext):
|
|||
if curses_library.startswith('ncurses'):
|
||||
curses_libs = [curses_library]
|
||||
self.add(Extension('_curses', ['_cursesmodule.c'],
|
||||
extra_compile_args=['-DPy_BUILD_CORE_MODULE'],
|
||||
include_dirs=curses_includes,
|
||||
define_macros=curses_defines,
|
||||
libraries=curses_libs))
|
||||
|
@ -1108,6 +1110,7 @@ class PyBuildExt(build_ext):
|
|||
curses_libs = ['curses']
|
||||
|
||||
self.add(Extension('_curses', ['_cursesmodule.c'],
|
||||
extra_compile_args=['-DPy_BUILD_CORE_MODULE'],
|
||||
define_macros=curses_defines,
|
||||
libraries=curses_libs))
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue