mirror of
https://github.com/python/cpython.git
synced 2025-11-24 12:20:42 +00:00
[3.14] GH-92266: Remove embedded tabs from `c-analyzer/cpython/_parser.py` (GH-137622) (#139718)
GH-92266: Remove embedded tabs from ``c-analyzer/cpython/_parser.py`` (GH-137622)
(cherry picked from commit 2212ae5557)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
This commit is contained in:
parent
c4be405fe9
commit
db8b943259
1 changed files with 215 additions and 231 deletions
|
|
@ -1,5 +1,4 @@
|
||||||
import os.path
|
import os.path
|
||||||
import re
|
|
||||||
|
|
||||||
from c_parser.preprocessor import (
|
from c_parser.preprocessor import (
|
||||||
get_preprocessor as _get_preprocessor,
|
get_preprocessor as _get_preprocessor,
|
||||||
|
|
@ -18,16 +17,16 @@ def _abs(relfile):
|
||||||
return os.path.join(REPO_ROOT, relfile)
|
return os.path.join(REPO_ROOT, relfile)
|
||||||
|
|
||||||
|
|
||||||
def clean_lines(text):
|
def format_conf_lines(lines):
|
||||||
"""Clear out comments, blank lines, and leading/trailing whitespace."""
|
"""Format conf entries for use in a TSV table."""
|
||||||
lines = (line.strip() for line in text.splitlines())
|
return [_abs(entry) for entry in lines]
|
||||||
lines = (line.partition('#')[0].rstrip()
|
|
||||||
for line in lines
|
|
||||||
if line and not line.startswith('#'))
|
def format_tsv_lines(lines):
|
||||||
glob_all = f'{GLOB_ALL} '
|
"""Format entries for use in a TSV table."""
|
||||||
lines = (re.sub(r'^[*] ', glob_all, line) for line in lines)
|
lines = ((_abs(first), *rest) for first, *rest in lines)
|
||||||
lines = (_abs(line) for line in lines)
|
lines = map('\t'.join, lines)
|
||||||
return list(lines)
|
return list(map(str.rstrip, lines))
|
||||||
|
|
||||||
|
|
||||||
'''
|
'''
|
||||||
|
|
@ -47,256 +46,241 @@ def clean_lines(text):
|
||||||
'''
|
'''
|
||||||
|
|
||||||
# XXX Handle these.
|
# XXX Handle these.
|
||||||
# Tab separated:
|
EXCLUDED = format_conf_lines([
|
||||||
EXCLUDED = clean_lines('''
|
# macOS
|
||||||
# @begin=conf@
|
'Modules/_scproxy.c', # SystemConfiguration/SystemConfiguration.h
|
||||||
|
|
||||||
# OSX
|
|
||||||
Modules/_scproxy.c # SystemConfiguration/SystemConfiguration.h
|
|
||||||
|
|
||||||
# Windows
|
# Windows
|
||||||
Modules/_winapi.c # windows.h
|
'Modules/_winapi.c', # windows.h
|
||||||
Modules/expat/winconfig.h
|
'Modules/expat/winconfig.h',
|
||||||
Modules/overlapped.c # winsock.h
|
'Modules/overlapped.c', # winsock.h
|
||||||
Python/dynload_win.c # windows.h
|
'Python/dynload_win.c', # windows.h
|
||||||
Python/thread_nt.h
|
'Python/thread_nt.h',
|
||||||
|
|
||||||
# other OS-dependent
|
# other OS-dependent
|
||||||
Python/dynload_aix.c # sys/ldr.h
|
'Python/dynload_aix.c', # sys/ldr.h
|
||||||
Python/dynload_dl.c # dl.h
|
'Python/dynload_dl.c', # dl.h
|
||||||
Python/dynload_hpux.c # dl.h
|
'Python/dynload_hpux.c', # dl.h
|
||||||
Python/emscripten_signal.c
|
'Python/emscripten_signal.c',
|
||||||
Python/emscripten_syscalls.c
|
'Python/emscripten_syscalls.c',
|
||||||
Python/emscripten_trampoline_inner.c
|
'Python/emscripten_trampoline_inner.c',
|
||||||
Python/thread_pthread.h
|
'Python/thread_pthread.h',
|
||||||
Python/thread_pthread_stubs.h
|
'Python/thread_pthread_stubs.h',
|
||||||
|
|
||||||
# only huge constants (safe but parsing is slow)
|
# only huge constants (safe but parsing is slow)
|
||||||
Modules/_ssl_data_*.h
|
'Modules/_ssl_data_*.h',
|
||||||
Modules/cjkcodecs/mappings_*.h
|
'Modules/cjkcodecs/mappings_*.h',
|
||||||
Modules/unicodedata_db.h
|
'Modules/unicodedata_db.h',
|
||||||
Modules/unicodename_db.h
|
'Modules/unicodename_db.h',
|
||||||
Objects/unicodetype_db.h
|
'Objects/unicodetype_db.h',
|
||||||
|
|
||||||
# generated
|
# generated
|
||||||
Python/deepfreeze/*.c
|
'Python/deepfreeze/*.c',
|
||||||
Python/frozen_modules/*.h
|
'Python/frozen_modules/*.h',
|
||||||
Python/generated_cases.c.h
|
'Python/generated_cases.c.h',
|
||||||
Python/executor_cases.c.h
|
'Python/executor_cases.c.h',
|
||||||
Python/optimizer_cases.c.h
|
'Python/optimizer_cases.c.h',
|
||||||
# XXX: Throws errors if PY_VERSION_HEX is not mocked out
|
# XXX: Throws errors if PY_VERSION_HEX is not mocked out
|
||||||
Modules/clinic/_testclinic_depr.c.h
|
'Modules/clinic/_testclinic_depr.c.h',
|
||||||
|
|
||||||
# not actually source
|
# not actually source
|
||||||
Python/bytecodes.c
|
'Python/bytecodes.c',
|
||||||
Python/optimizer_bytecodes.c
|
'Python/optimizer_bytecodes.c',
|
||||||
|
|
||||||
# mimalloc
|
# mimalloc
|
||||||
Objects/mimalloc/*.c
|
'Objects/mimalloc/*.c',
|
||||||
Include/internal/mimalloc/*.h
|
'Include/internal/mimalloc/*.h',
|
||||||
Include/internal/mimalloc/mimalloc/*.h
|
'Include/internal/mimalloc/mimalloc/*.h',
|
||||||
|
])
|
||||||
# @end=conf@
|
|
||||||
''')
|
|
||||||
|
|
||||||
# XXX Fix the parser.
|
# XXX Fix the parser.
|
||||||
EXCLUDED += clean_lines('''
|
EXCLUDED += format_conf_lines([
|
||||||
# The tool should be able to parse these...
|
# The tool should be able to parse these...
|
||||||
|
|
||||||
# The problem with xmlparse.c is that something
|
# The problem with xmlparse.c is that something
|
||||||
# has gone wrong where # we handle "maybe inline actual"
|
# has gone wrong where # we handle "maybe inline actual"
|
||||||
# in Tools/c-analyzer/c_parser/parser/_global.py.
|
# in Tools/c-analyzer/c_parser/parser/_global.py.
|
||||||
Modules/expat/internal.h
|
'Modules/expat/internal.h',
|
||||||
Modules/expat/xmlparse.c
|
'Modules/expat/xmlparse.c',
|
||||||
''')
|
])
|
||||||
|
|
||||||
INCL_DIRS = clean_lines('''
|
INCL_DIRS = format_tsv_lines([
|
||||||
# @begin=tsv@
|
# (glob, dirname)
|
||||||
|
|
||||||
glob dirname
|
('*', '.'),
|
||||||
* .
|
('*', './Include'),
|
||||||
* ./Include
|
('*', './Include/internal'),
|
||||||
* ./Include/internal
|
('*', './Include/internal/mimalloc'),
|
||||||
* ./Include/internal/mimalloc
|
|
||||||
|
|
||||||
Modules/_decimal/**/*.c Modules/_decimal/libmpdec
|
('Modules/_decimal/**/*.c', 'Modules/_decimal/libmpdec'),
|
||||||
Modules/_elementtree.c Modules/expat
|
('Modules/_elementtree.c', 'Modules/expat'),
|
||||||
Modules/_hacl/*.c Modules/_hacl/include
|
('Modules/_hacl/*.c', 'Modules/_hacl/include'),
|
||||||
Modules/_hacl/*.c Modules/_hacl/
|
('Modules/_hacl/*.c', 'Modules/_hacl/'),
|
||||||
Modules/_hacl/*.h Modules/_hacl/include
|
('Modules/_hacl/*.h', 'Modules/_hacl/include'),
|
||||||
Modules/_hacl/*.h Modules/_hacl/
|
('Modules/_hacl/*.h', 'Modules/_hacl/'),
|
||||||
Modules/md5module.c Modules/_hacl/include
|
('Modules/md5module.c', 'Modules/_hacl/include'),
|
||||||
Modules/sha1module.c Modules/_hacl/include
|
('Modules/sha1module.c', 'Modules/_hacl/include'),
|
||||||
Modules/sha2module.c Modules/_hacl/include
|
('Modules/sha2module.c', 'Modules/_hacl/include'),
|
||||||
Modules/sha3module.c Modules/_hacl/include
|
('Modules/sha3module.c', 'Modules/_hacl/include'),
|
||||||
Modules/blake2module.c Modules/_hacl/include
|
('Modules/blake2module.c', 'Modules/_hacl/include'),
|
||||||
Modules/hmacmodule.c Modules/_hacl/include
|
('Modules/hmacmodule.c', 'Modules/_hacl/include'),
|
||||||
Objects/stringlib/*.h Objects
|
('Objects/stringlib/*.h', 'Objects'),
|
||||||
|
|
||||||
# possible system-installed headers, just in case
|
# possible system-installed headers, just in case
|
||||||
Modules/_tkinter.c /usr/include/tcl8.6
|
('Modules/_tkinter.c', '/usr/include/tcl8.6'),
|
||||||
Modules/_uuidmodule.c /usr/include/uuid
|
('Modules/_uuidmodule.c', '/usr/include/uuid'),
|
||||||
Modules/tkappinit.c /usr/include/tcl
|
('Modules/tkappinit.c', '/usr/include/tcl'),
|
||||||
|
|
||||||
# @end=tsv@
|
])
|
||||||
''')[1:]
|
|
||||||
|
|
||||||
INCLUDES = clean_lines('''
|
INCLUDES = format_tsv_lines([
|
||||||
# @begin=tsv@
|
# (glob, include)
|
||||||
|
|
||||||
glob include
|
('**/*.h', 'Python.h'),
|
||||||
|
('Include/**/*.h', 'object.h'),
|
||||||
**/*.h Python.h
|
|
||||||
Include/**/*.h object.h
|
|
||||||
|
|
||||||
# for Py_HAVE_CONDVAR
|
# for Py_HAVE_CONDVAR
|
||||||
Include/internal/pycore_gil.h pycore_condvar.h
|
('Include/internal/pycore_gil.h', 'pycore_condvar.h'),
|
||||||
Python/thread_pthread.h pycore_condvar.h
|
('Python/thread_pthread.h', 'pycore_condvar.h'),
|
||||||
|
|
||||||
# other
|
# other
|
||||||
|
|
||||||
Objects/stringlib/join.h stringlib/stringdefs.h
|
('Objects/stringlib/join.h', 'stringlib/stringdefs.h'),
|
||||||
Objects/stringlib/ctype.h stringlib/stringdefs.h
|
('Objects/stringlib/ctype.h', 'stringlib/stringdefs.h'),
|
||||||
Objects/stringlib/transmogrify.h stringlib/stringdefs.h
|
('Objects/stringlib/transmogrify.h', 'stringlib/stringdefs.h'),
|
||||||
#Objects/stringlib/fastsearch.h stringlib/stringdefs.h
|
# ('Objects/stringlib/fastsearch.h', 'stringlib/stringdefs.h'),
|
||||||
#Objects/stringlib/count.h stringlib/stringdefs.h
|
# ('Objects/stringlib/count.h', 'stringlib/stringdefs.h'),
|
||||||
#Objects/stringlib/find.h stringlib/stringdefs.h
|
# ('Objects/stringlib/find.h', 'stringlib/stringdefs.h'),
|
||||||
#Objects/stringlib/partition.h stringlib/stringdefs.h
|
# ('Objects/stringlib/partition.h', 'stringlib/stringdefs.h'),
|
||||||
#Objects/stringlib/split.h stringlib/stringdefs.h
|
# ('Objects/stringlib/split.h', 'stringlib/stringdefs.h'),
|
||||||
Objects/stringlib/fastsearch.h stringlib/ucs1lib.h
|
('Objects/stringlib/fastsearch.h', 'stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/count.h stringlib/ucs1lib.h
|
('Objects/stringlib/count.h', 'stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/find.h stringlib/ucs1lib.h
|
('Objects/stringlib/find.h', 'stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/partition.h stringlib/ucs1lib.h
|
('Objects/stringlib/partition.h', 'stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/split.h stringlib/ucs1lib.h
|
('Objects/stringlib/split.h', 'stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/find_max_char.h Objects/stringlib/ucs1lib.h
|
('Objects/stringlib/find_max_char.h', 'Objects/stringlib/ucs1lib.h'),
|
||||||
Objects/stringlib/count.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/count.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
Objects/stringlib/find.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/find.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
Objects/stringlib/partition.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/partition.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
Objects/stringlib/replace.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/replace.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
Objects/stringlib/repr.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/repr.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
Objects/stringlib/split.h Objects/stringlib/fastsearch.h
|
('Objects/stringlib/split.h', 'Objects/stringlib/fastsearch.h'),
|
||||||
|
])
|
||||||
|
|
||||||
# @end=tsv@
|
MACROS = format_tsv_lines([
|
||||||
''')[1:]
|
# (glob, name, value)
|
||||||
|
|
||||||
MACROS = clean_lines('''
|
('Include/internal/*.h', 'Py_BUILD_CORE', '1'),
|
||||||
# @begin=tsv@
|
('Python/**/*.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Python/**/*.h', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Parser/**/*.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Parser/**/*.h', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Objects/**/*.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Objects/**/*.h', 'Py_BUILD_CORE', '1'),
|
||||||
|
|
||||||
glob name value
|
('Modules/_asynciomodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_codecsmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_collectionsmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_ctypes/_ctypes.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_ctypes/cfield.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_cursesmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_datetimemodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_functoolsmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_heapqmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_io/*.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_io/*.h', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_localemodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_operator.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_posixsubprocess.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_sre/sre.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_threadmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_tracemalloc.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_weakref.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/_zoneinfo.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/atexitmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/cmathmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/faulthandler.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/gcmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/getpath.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/getpath_noop.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/itertoolsmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/main.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/mathmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/posixmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/sha256module.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/sha512module.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/signalmodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/symtablemodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/timemodule.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
('Modules/unicodedata.c', 'Py_BUILD_CORE', '1'),
|
||||||
|
|
||||||
Include/internal/*.h Py_BUILD_CORE 1
|
('Modules/_json.c', 'Py_BUILD_CORE_BUILTIN', '1'),
|
||||||
Python/**/*.c Py_BUILD_CORE 1
|
('Modules/_pickle.c', 'Py_BUILD_CORE_BUILTIN', '1'),
|
||||||
Python/**/*.h Py_BUILD_CORE 1
|
('Modules/_testinternalcapi.c', 'Py_BUILD_CORE_BUILTIN', '1'),
|
||||||
Parser/**/*.c Py_BUILD_CORE 1
|
|
||||||
Parser/**/*.h Py_BUILD_CORE 1
|
|
||||||
Objects/**/*.c Py_BUILD_CORE 1
|
|
||||||
Objects/**/*.h Py_BUILD_CORE 1
|
|
||||||
|
|
||||||
Modules/_asynciomodule.c Py_BUILD_CORE 1
|
('Include/cpython/abstract.h', 'Py_CPYTHON_ABSTRACTOBJECT_H', '1'),
|
||||||
Modules/_codecsmodule.c Py_BUILD_CORE 1
|
('Include/cpython/bytearrayobject.h', 'Py_CPYTHON_BYTEARRAYOBJECT_H', '1'),
|
||||||
Modules/_collectionsmodule.c Py_BUILD_CORE 1
|
('Include/cpython/bytesobject.h', 'Py_CPYTHON_BYTESOBJECT_H', '1'),
|
||||||
Modules/_ctypes/_ctypes.c Py_BUILD_CORE 1
|
('Include/cpython/ceval.h', 'Py_CPYTHON_CEVAL_H', '1'),
|
||||||
Modules/_ctypes/cfield.c Py_BUILD_CORE 1
|
('Include/cpython/code.h', 'Py_CPYTHON_CODE_H', '1'),
|
||||||
Modules/_cursesmodule.c Py_BUILD_CORE 1
|
('Include/cpython/dictobject.h', 'Py_CPYTHON_DICTOBJECT_H', '1'),
|
||||||
Modules/_datetimemodule.c Py_BUILD_CORE 1
|
('Include/cpython/fileobject.h', 'Py_CPYTHON_FILEOBJECT_H', '1'),
|
||||||
Modules/_functoolsmodule.c Py_BUILD_CORE 1
|
('Include/cpython/fileutils.h', 'Py_CPYTHON_FILEUTILS_H', '1'),
|
||||||
Modules/_heapqmodule.c Py_BUILD_CORE 1
|
('Include/cpython/frameobject.h', 'Py_CPYTHON_FRAMEOBJECT_H', '1'),
|
||||||
Modules/_io/*.c Py_BUILD_CORE 1
|
('Include/cpython/import.h', 'Py_CPYTHON_IMPORT_H', '1'),
|
||||||
Modules/_io/*.h Py_BUILD_CORE 1
|
('Include/cpython/interpreteridobject.h', 'Py_CPYTHON_INTERPRETERIDOBJECT_H', '1'),
|
||||||
Modules/_localemodule.c Py_BUILD_CORE 1
|
('Include/cpython/listobject.h', 'Py_CPYTHON_LISTOBJECT_H', '1'),
|
||||||
Modules/_operator.c Py_BUILD_CORE 1
|
('Include/cpython/methodobject.h', 'Py_CPYTHON_METHODOBJECT_H', '1'),
|
||||||
Modules/_posixsubprocess.c Py_BUILD_CORE 1
|
('Include/cpython/object.h', 'Py_CPYTHON_OBJECT_H', '1'),
|
||||||
Modules/_sre/sre.c Py_BUILD_CORE 1
|
('Include/cpython/objimpl.h', 'Py_CPYTHON_OBJIMPL_H', '1'),
|
||||||
Modules/_threadmodule.c Py_BUILD_CORE 1
|
('Include/cpython/pyerrors.h', 'Py_CPYTHON_ERRORS_H', '1'),
|
||||||
Modules/_tracemalloc.c Py_BUILD_CORE 1
|
('Include/cpython/pylifecycle.h', 'Py_CPYTHON_PYLIFECYCLE_H', '1'),
|
||||||
Modules/_weakref.c Py_BUILD_CORE 1
|
('Include/cpython/pymem.h', 'Py_CPYTHON_PYMEM_H', '1'),
|
||||||
Modules/_zoneinfo.c Py_BUILD_CORE 1
|
('Include/cpython/pystate.h', 'Py_CPYTHON_PYSTATE_H', '1'),
|
||||||
Modules/atexitmodule.c Py_BUILD_CORE 1
|
('Include/cpython/sysmodule.h', 'Py_CPYTHON_SYSMODULE_H', '1'),
|
||||||
Modules/cmathmodule.c Py_BUILD_CORE 1
|
('Include/cpython/traceback.h', 'Py_CPYTHON_TRACEBACK_H', '1'),
|
||||||
Modules/faulthandler.c Py_BUILD_CORE 1
|
('Include/cpython/tupleobject.h', 'Py_CPYTHON_TUPLEOBJECT_H', '1'),
|
||||||
Modules/gcmodule.c Py_BUILD_CORE 1
|
('Include/cpython/unicodeobject.h', 'Py_CPYTHON_UNICODEOBJECT_H', '1'),
|
||||||
Modules/getpath.c Py_BUILD_CORE 1
|
|
||||||
Modules/getpath_noop.c Py_BUILD_CORE 1
|
|
||||||
Modules/itertoolsmodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/main.c Py_BUILD_CORE 1
|
|
||||||
Modules/mathmodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/posixmodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/sha256module.c Py_BUILD_CORE 1
|
|
||||||
Modules/sha512module.c Py_BUILD_CORE 1
|
|
||||||
Modules/signalmodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/symtablemodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/timemodule.c Py_BUILD_CORE 1
|
|
||||||
Modules/unicodedata.c Py_BUILD_CORE 1
|
|
||||||
|
|
||||||
Modules/_json.c Py_BUILD_CORE_BUILTIN 1
|
|
||||||
Modules/_pickle.c Py_BUILD_CORE_BUILTIN 1
|
|
||||||
Modules/_testinternalcapi.c Py_BUILD_CORE_BUILTIN 1
|
|
||||||
|
|
||||||
Include/cpython/abstract.h Py_CPYTHON_ABSTRACTOBJECT_H 1
|
|
||||||
Include/cpython/bytearrayobject.h Py_CPYTHON_BYTEARRAYOBJECT_H 1
|
|
||||||
Include/cpython/bytesobject.h Py_CPYTHON_BYTESOBJECT_H 1
|
|
||||||
Include/cpython/ceval.h Py_CPYTHON_CEVAL_H 1
|
|
||||||
Include/cpython/code.h Py_CPYTHON_CODE_H 1
|
|
||||||
Include/cpython/dictobject.h Py_CPYTHON_DICTOBJECT_H 1
|
|
||||||
Include/cpython/fileobject.h Py_CPYTHON_FILEOBJECT_H 1
|
|
||||||
Include/cpython/fileutils.h Py_CPYTHON_FILEUTILS_H 1
|
|
||||||
Include/cpython/frameobject.h Py_CPYTHON_FRAMEOBJECT_H 1
|
|
||||||
Include/cpython/import.h Py_CPYTHON_IMPORT_H 1
|
|
||||||
Include/cpython/interpreteridobject.h Py_CPYTHON_INTERPRETERIDOBJECT_H 1
|
|
||||||
Include/cpython/listobject.h Py_CPYTHON_LISTOBJECT_H 1
|
|
||||||
Include/cpython/methodobject.h Py_CPYTHON_METHODOBJECT_H 1
|
|
||||||
Include/cpython/object.h Py_CPYTHON_OBJECT_H 1
|
|
||||||
Include/cpython/objimpl.h Py_CPYTHON_OBJIMPL_H 1
|
|
||||||
Include/cpython/pyerrors.h Py_CPYTHON_ERRORS_H 1
|
|
||||||
Include/cpython/pylifecycle.h Py_CPYTHON_PYLIFECYCLE_H 1
|
|
||||||
Include/cpython/pymem.h Py_CPYTHON_PYMEM_H 1
|
|
||||||
Include/cpython/pystate.h Py_CPYTHON_PYSTATE_H 1
|
|
||||||
Include/cpython/sysmodule.h Py_CPYTHON_SYSMODULE_H 1
|
|
||||||
Include/cpython/traceback.h Py_CPYTHON_TRACEBACK_H 1
|
|
||||||
Include/cpython/tupleobject.h Py_CPYTHON_TUPLEOBJECT_H 1
|
|
||||||
Include/cpython/unicodeobject.h Py_CPYTHON_UNICODEOBJECT_H 1
|
|
||||||
|
|
||||||
# implied include of <unistd.h>
|
# implied include of <unistd.h>
|
||||||
Include/**/*.h _POSIX_THREADS 1
|
('Include/**/*.h', '_POSIX_THREADS', '1'),
|
||||||
Include/**/*.h HAVE_PTHREAD_H 1
|
('Include/**/*.h', 'HAVE_PTHREAD_H', '1'),
|
||||||
|
|
||||||
# from pyconfig.h
|
# from pyconfig.h
|
||||||
Include/cpython/pthread_stubs.h HAVE_PTHREAD_STUBS 1
|
('Include/cpython/pthread_stubs.h', 'HAVE_PTHREAD_STUBS', '1'),
|
||||||
Python/thread_pthread_stubs.h HAVE_PTHREAD_STUBS 1
|
('Python/thread_pthread_stubs.h', 'HAVE_PTHREAD_STUBS', '1'),
|
||||||
|
|
||||||
# from Objects/bytesobject.c
|
# from Objects/bytesobject.c
|
||||||
Objects/stringlib/partition.h STRINGLIB_GET_EMPTY() bytes_get_empty()
|
('Objects/stringlib/partition.h', 'STRINGLIB_GET_EMPTY()', 'bytes_get_empty()'),
|
||||||
Objects/stringlib/join.h STRINGLIB_MUTABLE 0
|
('Objects/stringlib/join.h', 'STRINGLIB_MUTABLE', '0'),
|
||||||
Objects/stringlib/partition.h STRINGLIB_MUTABLE 0
|
('Objects/stringlib/partition.h', 'STRINGLIB_MUTABLE', '0'),
|
||||||
Objects/stringlib/split.h STRINGLIB_MUTABLE 0
|
('Objects/stringlib/split.h', 'STRINGLIB_MUTABLE', '0'),
|
||||||
Objects/stringlib/transmogrify.h STRINGLIB_MUTABLE 0
|
('Objects/stringlib/transmogrify.h', 'STRINGLIB_MUTABLE', '0'),
|
||||||
|
|
||||||
# from Makefile
|
# from Makefile
|
||||||
Modules/getpath.c PYTHONPATH 1
|
('Modules/getpath.c', 'PYTHONPATH', '1'),
|
||||||
Modules/getpath.c PREFIX ...
|
('Modules/getpath.c', 'PREFIX', '...'),
|
||||||
Modules/getpath.c EXEC_PREFIX ...
|
('Modules/getpath.c', 'EXEC_PREFIX', '...'),
|
||||||
Modules/getpath.c VERSION ...
|
('Modules/getpath.c', 'VERSION', '...'),
|
||||||
Modules/getpath.c VPATH ...
|
('Modules/getpath.c', 'VPATH', '...'),
|
||||||
Modules/getpath.c PLATLIBDIR ...
|
('Modules/getpath.c', 'PLATLIBDIR', '...'),
|
||||||
#Modules/_dbmmodule.c USE_GDBM_COMPAT 1
|
# ('Modules/_dbmmodule.c', 'USE_GDBM_COMPAT', '1'),
|
||||||
Modules/_dbmmodule.c USE_NDBM 1
|
('Modules/_dbmmodule.c', 'USE_NDBM', '1'),
|
||||||
#Modules/_dbmmodule.c USE_BERKDB 1
|
# ('Modules/_dbmmodule.c', 'USE_BERKDB', '1'),
|
||||||
|
|
||||||
# See: setup.py
|
# See: setup.py
|
||||||
Modules/_decimal/**/*.c CONFIG_64 1
|
('Modules/_decimal/**/*.c', 'CONFIG_64', '1'),
|
||||||
Modules/_decimal/**/*.c ASM 1
|
('Modules/_decimal/**/*.c', 'ASM', '1'),
|
||||||
Modules/expat/xmlparse.c HAVE_EXPAT_CONFIG_H 1
|
('Modules/expat/xmlparse.c', 'HAVE_EXPAT_CONFIG_H', '1'),
|
||||||
Modules/expat/xmlparse.c XML_POOR_ENTROPY 1
|
('Modules/expat/xmlparse.c', 'XML_POOR_ENTROPY', '1'),
|
||||||
Modules/_dbmmodule.c HAVE_GDBM_DASH_NDBM_H 1
|
('Modules/_dbmmodule.c', 'HAVE_GDBM_DASH_NDBM_H', '1'),
|
||||||
|
|
||||||
# others
|
# others
|
||||||
Modules/_sre/sre_lib.h LOCAL(type) static inline type
|
('Modules/_sre/sre_lib.h', 'LOCAL(type)', 'static inline type'),
|
||||||
Modules/_sre/sre_lib.h SRE(F) sre_ucs2_##F
|
('Modules/_sre/sre_lib.h', 'SRE(F)', 'sre_ucs2_##F'),
|
||||||
Objects/stringlib/codecs.h STRINGLIB_IS_UNICODE 1
|
('Objects/stringlib/codecs.h', 'STRINGLIB_IS_UNICODE', '1'),
|
||||||
Include/internal/pycore_crossinterp_data_registry.h Py_CORE_CROSSINTERP_DATA_REGISTRY_H 1
|
('Include/internal/pycore_crossinterp_data_registry.h', 'Py_CORE_CROSSINTERP_DATA_REGISTRY_H', '1'),
|
||||||
|
])
|
||||||
# @end=tsv@
|
|
||||||
''')[1:]
|
|
||||||
|
|
||||||
# -pthread
|
# -pthread
|
||||||
# -Wno-unused-result
|
# -Wno-unused-result
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue