mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
bpo-42333: Port _ssl extension to multiphase initialization (PEP 489) (GH-23253)
- Introduce sslmodule_slots - Introduce sslmodulestate - Use sslmodulestate - Get rid of PyState_FindModule - Move new structs and helpers to header file - Use macros to access state - Keep a strong ref to socket type
This commit is contained in:
parent
76beadb8ff
commit
7f1305ef9e
6 changed files with 468 additions and 366 deletions
10
setup.py
10
setup.py
|
|
@ -2428,14 +2428,6 @@ class PyBuildExt(build_ext):
|
|||
self.missing.extend(['_ssl', '_hashlib'])
|
||||
return None, None
|
||||
|
||||
self.add(Extension(
|
||||
'_ssl', ['_ssl.c'],
|
||||
include_dirs=openssl_includes,
|
||||
library_dirs=openssl_libdirs,
|
||||
libraries=openssl_libs,
|
||||
depends=['socketmodule.h', '_ssl/debughelpers.c'])
|
||||
)
|
||||
|
||||
if openssl_rpath == 'auto':
|
||||
runtime_library_dirs = openssl_libdirs[:]
|
||||
elif not openssl_rpath:
|
||||
|
|
@ -2469,7 +2461,7 @@ class PyBuildExt(build_ext):
|
|||
Extension(
|
||||
'_ssl',
|
||||
['_ssl.c'],
|
||||
depends=['socketmodule.h', '_ssl/debughelpers.c'],
|
||||
depends=['socketmodule.h', '_ssl/debughelpers.c', '_ssl.h'],
|
||||
**openssl_extension_kwargs
|
||||
)
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue