Skip to content

Commit 3c7000a

Browse files
committed
Fix Windows build (again)
1 parent 22bbdcd commit 3c7000a

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

Modules/_testinternalcapi/test_critical_sections.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,12 @@
33
*/
44

55
#include "parts.h"
6-
76
#include "pycore_critical_section.h"
87

8+
#ifdef MS_WINDOWS
9+
# include <windows.h> // Sleep()
10+
#endif
11+
912
#ifdef Py_GIL_DISABLED
1013
#define assert_nogil assert
1114
#define assert_gil(x)

Modules/_winapi.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@
3838
#include "pycore_moduleobject.h" // _PyModule_GetState()
3939
#include "pycore_pylifecycle.h" // _Py_IsInterpreterFinalizing()
4040
#include "pycore_pystate.h" // _PyInterpreterState_GET
41-
41+
#include "pycore_unicodeobject.h" // for Argument Clinic
4242

4343

4444
#ifndef WINDOWS_LEAN_AND_MEAN
45-
#define WINDOWS_LEAN_AND_MEAN
45+
# define WINDOWS_LEAN_AND_MEAN
4646
#endif
47-
#include "windows.h"
47+
#include <windows.h>
4848
#include <winioctl.h>
4949
#include <crtdbg.h>
5050
#include "winreparse.h"

Python/dynload_win.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33

44
#include "Python.h"
55
#include "pycore_fileutils.h" // _Py_add_relfile()
6+
#include "pycore_importdl.h" // dl_funcptr
7+
#include "pycore_interp.h" // _PyInterpreterState_GetConfig()
68
#include "pycore_pystate.h" // _PyInterpreterState_GET()
79

8-
#include "pycore_importdl.h" // dl_funcptr
910
#include "patchlevel.h" // PY_MAJOR_VERSION
1011
#include <windows.h>
1112

0 commit comments

Comments
 (0)