File tree Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Original file line number Diff line number Diff line change 39
39
40
40
#define WINDOWS_LEAN_AND_MEAN
41
41
#include "windows.h"
42
+ #if defined(Py_DEBUG )
42
43
#include <crtdbg.h>
44
+ #endif
43
45
44
46
#if defined(MS_WIN32 ) && !defined(MS_WIN64 )
45
47
#define HANDLE_TO_PYNUM (handle ) \
Original file line number Diff line number Diff line change 21
21
#include <io.h>
22
22
#include <conio.h>
23
23
#include <sys/locking.h>
24
+ #ifdef _DEBUG
24
25
#include <crtdbg.h>
26
+ #endif
25
27
#include <windows.h>
26
28
27
29
#ifdef _MSC_VER
Original file line number Diff line number Diff line change @@ -887,6 +887,16 @@ def detect_modules(self):
887
887
min_db_ver = (3 , 3 )
888
888
db_setup_debug = False # verbose debug prints from this script?
889
889
890
+ # Modules with some Windows dependencies:
891
+ if host_platform .startswith (('mingw' , 'win' )):
892
+ srcdir = sysconfig .get_config_var ('srcdir' )
893
+ pc_srcdir = os .path .abspath (os .path .join (srcdir , 'PC' ))
894
+
895
+ exts .append ( Extension ('msvcrt' , [os .path .join (pc_srcdir , p )
896
+ for p in ['msvcrtmodule.c' ]]) )
897
+
898
+ exts .append ( Extension ('_winapi' , ['_winapi.c' ]) )
899
+
890
900
def allow_db_ver (db_ver ):
891
901
"""Returns a boolean if the given BerkeleyDB version is acceptable.
892
902
You can’t perform that action at this time.
0 commit comments