aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Python
diff options
context:
space:
mode:
authorSam Gross <colesbury@gmail.com>2023-10-04 22:50:29 +0000
committerGitHub <noreply@github.com>2023-10-04 22:50:29 +0000
commitcf6f23b0e3cdef33f23967cf954a2ca4d1fa6528 (patch)
tree81af760a78ee03470d1fb1abbd13d35a24ad6cc3 /Python
parent80dc39e1dc2abc809f448cba5d2c5b9c1c631e11 (diff)
downloadcpython-cf6f23b0e3cdef33f23967cf954a2ca4d1fa6528.tar.gz
cpython-cf6f23b0e3cdef33f23967cf954a2ca4d1fa6528.zip
gh-88402: Add new sysconfig variables on Windows (GH-110049)
Co-authored-by: Filipe LaĆ­ns <filipe.lains@gmail.com>
Diffstat (limited to 'Python')
-rw-r--r--Python/dynload_hpux.c2
-rw-r--r--Python/dynload_shlib.c2
-rw-r--r--Python/dynload_stub.c2
-rw-r--r--Python/dynload_win.c22
-rw-r--r--Python/import.c2
-rw-r--r--Python/importdl.c2
-rw-r--r--Python/importdl.h29
-rw-r--r--Python/stdlib_module_names.h1
8 files changed, 7 insertions, 55 deletions
diff --git a/Python/dynload_hpux.c b/Python/dynload_hpux.c
index a53373038ed..1c44722ff9a 100644
--- a/Python/dynload_hpux.c
+++ b/Python/dynload_hpux.c
@@ -5,7 +5,7 @@
#include <errno.h>
#include "Python.h"
-#include "importdl.h"
+#include "pycore_importdl.h"
#if defined(__hp9000s300)
#define FUNCNAME_PATTERN "_%.20s_%.200s"
diff --git a/Python/dynload_shlib.c b/Python/dynload_shlib.c
index 6761bba4579..5a37a83805b 100644
--- a/Python/dynload_shlib.c
+++ b/Python/dynload_shlib.c
@@ -4,7 +4,7 @@
#include "Python.h"
#include "pycore_interp.h" // _PyInterpreterState.dlopenflags
#include "pycore_pystate.h" // _PyInterpreterState_GET()
-#include "importdl.h"
+#include "pycore_importdl.h"
#include <sys/types.h>
#include <sys/stat.h>
diff --git a/Python/dynload_stub.c b/Python/dynload_stub.c
index 59160483caa..11f7e5f643f 100644
--- a/Python/dynload_stub.c
+++ b/Python/dynload_stub.c
@@ -3,7 +3,7 @@
not present. */
#include "Python.h"
-#include "importdl.h"
+#include "pycore_importdl.h"
const char *_PyImport_DynLoadFiletab[] = {NULL};
diff --git a/Python/dynload_win.c b/Python/dynload_win.c
index fcb3cb74404..a0ac31c80a5 100644
--- a/Python/dynload_win.c
+++ b/Python/dynload_win.c
@@ -5,30 +5,10 @@
#include "pycore_fileutils.h" // _Py_add_relfile()
#include "pycore_pystate.h" // _PyInterpreterState_GET()
-#include "importdl.h" // dl_funcptr
+#include "pycore_importdl.h" // dl_funcptr
#include "patchlevel.h" // PY_MAJOR_VERSION
#include <windows.h>
-#ifdef _DEBUG
-#define PYD_DEBUG_SUFFIX "_d"
-#else
-#define PYD_DEBUG_SUFFIX ""
-#endif
-
-#ifdef Py_NOGIL
-# define PYD_THREADING_TAG "t"
-#else
-# define PYD_THREADING_TAG ""
-#endif
-
-#ifdef PYD_PLATFORM_TAG
-#define PYD_TAGGED_SUFFIX PYD_DEBUG_SUFFIX ".cp" Py_STRINGIFY(PY_MAJOR_VERSION) Py_STRINGIFY(PY_MINOR_VERSION) PYD_THREADING_TAG "-" PYD_PLATFORM_TAG ".pyd"
-#else
-#define PYD_TAGGED_SUFFIX PYD_DEBUG_SUFFIX ".cp" Py_STRINGIFY(PY_MAJOR_VERSION) Py_STRINGIFY(PY_MINOR_VERSION) PYD_THREADING_TAG ".pyd"
-#endif
-
-#define PYD_UNTAGGED_SUFFIX PYD_DEBUG_SUFFIX ".pyd"
-
const char *_PyImport_DynLoadFiletab[] = {
PYD_TAGGED_SUFFIX,
PYD_UNTAGGED_SUFFIX,
diff --git a/Python/import.c b/Python/import.c
index 5636968ed9e..cafdd834502 100644
--- a/Python/import.c
+++ b/Python/import.c
@@ -17,7 +17,7 @@
#include "pycore_weakref.h" // _PyWeakref_GET_REF()
#include "marshal.h" // PyMarshal_ReadObjectFromString()
-#include "importdl.h" // _PyImport_DynLoadFiletab
+#include "pycore_importdl.h" // _PyImport_DynLoadFiletab
#include "pydtrace.h" // PyDTrace_IMPORT_FIND_LOAD_START_ENABLED()
#include <stdbool.h> // bool
diff --git a/Python/importdl.c b/Python/importdl.c
index 9ab0a5ad33a..7dfd301d77e 100644
--- a/Python/importdl.c
+++ b/Python/importdl.c
@@ -15,7 +15,7 @@
*/
#ifdef HAVE_DYNAMIC_LOADING
-#include "importdl.h"
+#include "pycore_importdl.h"
#ifdef MS_WINDOWS
extern dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix,
diff --git a/Python/importdl.h b/Python/importdl.h
deleted file mode 100644
index 9171adc2770..00000000000
--- a/Python/importdl.h
+++ /dev/null
@@ -1,29 +0,0 @@
-#ifndef Py_IMPORTDL_H
-#define Py_IMPORTDL_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-extern const char *_PyImport_DynLoadFiletab[];
-
-extern PyObject *_PyImport_LoadDynamicModuleWithSpec(PyObject *spec, FILE *);
-
-typedef PyObject *(*PyModInitFunction)(void);
-
-/* Max length of module suffix searched for -- accommodates "module.slb" */
-#define MAXSUFFIXSIZE 12
-
-#ifdef MS_WINDOWS
-#include <windows.h>
-typedef FARPROC dl_funcptr;
-#else
-typedef void (*dl_funcptr)(void);
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-#endif /* !Py_IMPORTDL_H */
diff --git a/Python/stdlib_module_names.h b/Python/stdlib_module_names.h
index 13b1764f088..701bfc35cc8 100644
--- a/Python/stdlib_module_names.h
+++ b/Python/stdlib_module_names.h
@@ -77,6 +77,7 @@ static const char* _Py_stdlib_module_names[] = {
"_strptime",
"_struct",
"_symtable",
+"_sysconfig",
"_thread",
"_threading_local",
"_tkinter",