diff -Naur Python-3.7.0-orig/Python/sysmodule.c Python-3.7.0/Python/sysmodule.c --- Python-3.7.0-orig/Python/sysmodule.c 2018-06-27 06:07:35.000000000 +0300 +++ Python-3.7.0/Python/sysmodule.c 2018-07-12 10:22:32.476878500 +0300 @@ -28,7 +28,7 @@ #include #endif /* MS_WINDOWS */ -#ifdef MS_COREDLL +#if defined(MS_WINDOWS) && defined(Py_ENABLE_SHARED) extern void *PyWin_DLLhModule; /* A string loaded from the DLL at startup: */ extern const char *PyWin_DLLVersionString; @@ -2333,7 +2333,7 @@ PyUnicode_FromString("little")); #endif -#ifdef MS_COREDLL +#if defined(MS_WINDOWS) && defined(Py_ENABLE_SHARED) SET_SYS_FROM_STRING("dllhandle", PyLong_FromVoidPtr(PyWin_DLLhModule)); SET_SYS_FROM_STRING("winver",