diff options
-rw-r--r-- | external/python3/0001-remove-long-double-from-ctypes-value-union.patch.1 | 34 | ||||
-rw-r--r-- | external/python3/UnpackedTarball_python3.mk | 1 |
2 files changed, 35 insertions, 0 deletions
diff --git a/external/python3/0001-remove-long-double-from-ctypes-value-union.patch.1 b/external/python3/0001-remove-long-double-from-ctypes-value-union.patch.1 new file mode 100644 index 000000000000..8cdaf84de37c --- /dev/null +++ b/external/python3/0001-remove-long-double-from-ctypes-value-union.patch.1 @@ -0,0 +1,34 @@ +From 6d999803a07ef5e01f0048d4f276e9cf4401a23d Mon Sep 17 00:00:00 2001 +From: Benjamin Peterson <benjamin@python.org> +Date: Mon, 5 Sep 2016 16:24:52 -0700 +Subject: [PATCH] remove long double from ctypes value union + +It is unused. It also forces a 16-byte alignment, which creates problems because +Python's allocator only uses 8-byte alignment. +--- + Modules/_ctypes/ctypes.h | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/Modules/_ctypes/ctypes.h b/Modules/_ctypes/ctypes.h +index 0d3f7241ca..d80ea82cee 100644 +--- a/Modules/_ctypes/ctypes.h ++++ b/Modules/_ctypes/ctypes.h +@@ -34,7 +34,6 @@ union value { + #ifdef HAVE_LONG_LONG + PY_LONG_LONG ll; + #endif +- long double D; + }; + + /* +@@ -306,7 +305,6 @@ struct tagPyCArgObject { + #ifdef HAVE_LONG_LONG + PY_LONG_LONG q; + #endif +- long double D; + double d; + float f; + void *p; +-- +2.31.1 + diff --git a/external/python3/UnpackedTarball_python3.mk b/external/python3/UnpackedTarball_python3.mk index f231b5970eaf..41d9e4d78ff5 100644 --- a/external/python3/UnpackedTarball_python3.mk +++ b/external/python3/UnpackedTarball_python3.mk @@ -28,6 +28,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,python3,\ external/python3/darwin.patch.0 \ external/python3/0001-3.6-bpo-17239-Disable-external-entities-in-SAX-parse.patch.1 \ external/python3/0001-3.6-closes-bpo-42938-Replace-snprintf-with-Python-un.patch.1 \ + external/python3/0001-remove-long-double-from-ctypes-value-union.patch.1 \ )) ifneq ($(filter DRAGONFLY FREEBSD LINUX NETBSD OPENBSD SOLARIS,$(OS)),) |