* Initial python-3.7 port * python3: Add setup.config.in to remove before patching * python3: Implement setenv for mingw. Fix building with NT threads. Build with unicode * Fix typos * Fix linking core modules * Mingw build have exec_prefix * Remove deprecated patch * Fix building python and modules. Failing to build readline module and install not working yet * More getpath changes and more aggressive path separator conversion * Fix readline module compilation and linking errors * python3: By default building with posix threads, NT threads are broken. Some patches optimization. First buildable commit * Py_DecodeLocale handle char, not wchar * Fix building multiprocessing module with posix threads
15 lines
686 B
Diff
15 lines
686 B
Diff
diff -Naur Python-3.7.0-orig/Lib/ctypes/__init__.py Python-3.7.0/Lib/ctypes/__init__.py
|
|
--- Python-3.7.0-orig/Lib/ctypes/__init__.py 2018-06-27 06:07:35.000000000 +0300
|
|
+++ Python-3.7.0/Lib/ctypes/__init__.py 2018-06-30 11:17:44.326377200 +0300
|
|
@@ -436,7 +436,9 @@
|
|
cdll = LibraryLoader(CDLL)
|
|
pydll = LibraryLoader(PyDLL)
|
|
|
|
-if _os.name == "nt":
|
|
+if _os.name == "nt" and _sys.version.find('GCC') >= 0:
|
|
+ pythonapi = PyDLL("libpython%d.%d%s.dll" % (_sys.version_info[:2] + (_sys.abiflags,)), None)
|
|
+elif _os.name == "nt":
|
|
pythonapi = PyDLL("python dll", None, _sys.dllhandle)
|
|
elif _sys.platform == "cygwin":
|
|
pythonapi = PyDLL("libpython%d.%d.dll" % _sys.version_info[:2])
|