diff options
author | Tobias Kunze | 2022-05-25 00:57:04 +0200 |
---|---|---|
committer | Tobias Kunze | 2022-05-25 03:11:06 +0200 |
commit | e33c58eda20b03d209774322f83dd97650cf7feb (patch) | |
tree | 4032811e23757f53893b04075f947acd708f03a9 | |
parent | 287e314a415b05dcaeb2e9aa9325d3b08dc05c27 (diff) | |
download | aur-e33c58eda20b03d209774322f83dd97650cf7feb.tar.gz |
Include 16 bit patch by @thatch
https://github.com/rixx/pkgbuilds/pull/13
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 11 | ||||
-rw-r--r-- | alignment.patch | 24 |
3 files changed, 35 insertions, 4 deletions
@@ -1,7 +1,7 @@ pkgbase = python36 pkgdesc = Major release 3.6 of the Python high-level programming language pkgver = 3.6.15 - pkgrel = 4 + pkgrel = 5 url = http://www.python.org/ arch = i686 arch = x86_64 @@ -22,6 +22,8 @@ pkgbase = python36 optdepends = sqlite provides = python=3.6.15 source = http://www.python.org/ftp/python/3.6.15/Python-3.6.15.tar.xz + source = alignment.patch sha256sums = 6e28d7cdd6dd513dd190e49bca3972e20fcf455090ccf2ef3f1a227614135d91 + sha256sums = SKIP pkgname = python36 @@ -3,7 +3,7 @@ pkgname=python36 pkgver=3.6.15 -pkgrel=4 +pkgrel=5 _pybasever=3.6 _pymajver=3 pkgdesc="Major release 3.6 of the Python high-level programming language" @@ -13,8 +13,8 @@ url="http://www.python.org/" depends=('expat' 'bzip2' 'gdbm' 'openssl' 'libffi' 'zlib') makedepends=('tk' 'sqlite' 'bluez-libs' 'mpdecimal') optdepends=('tk: for tkinter' 'sqlite') -source=(http://www.python.org/ftp/python/${pkgver}/Python-${pkgver}.tar.xz) -sha256sums=('6e28d7cdd6dd513dd190e49bca3972e20fcf455090ccf2ef3f1a227614135d91') +source=(http://www.python.org/ftp/python/${pkgver}/Python-${pkgver}.tar.xz alignment.patch) +sha256sums=('6e28d7cdd6dd513dd190e49bca3972e20fcf455090ccf2ef3f1a227614135d91' SKIP) provides=("python=$pkgver") prepare() { @@ -23,6 +23,11 @@ prepare() { # FS#23997 sed -i -e "s|^#.* /usr/local/bin/python|#!/usr/bin/python|" Lib/cgi.py + msg "fix alignment issue (issue27987)" + # via https://github.com/pyenv/pyenv/issues/1889 + # and https://bugs.python.org/file44413/alignment.patch + patch -p1 < ../alignment.patch + # Ensure that we are using the system copy of various libraries (expat, zlib and libffi), # rather than copies shipped in the tarball rm -rf Modules/expat diff --git a/alignment.patch b/alignment.patch new file mode 100644 index 000000000000..969302049da2 --- /dev/null +++ b/alignment.patch @@ -0,0 +1,24 @@ +--- a/Include/objimpl.h ++++ b/Include/objimpl.h +@@ -250,7 +250,7 @@ + union _gc_head *gc_prev; + Py_ssize_t gc_refs; + } gc; +- double dummy; /* force worst-case alignment */ ++ long double dummy; /* force worst-case alignment */ + } PyGC_Head; + + extern PyGC_Head *_PyGC_generation0; +--- a/Objects/obmalloc.c ++++ b/Objects/obmalloc.c +@@ -643,8 +643,8 @@ + * + * You shouldn't change this unless you know what you are doing. + */ +-#define ALIGNMENT 8 /* must be 2^N */ +-#define ALIGNMENT_SHIFT 3 ++#define ALIGNMENT 16 /* must be 2^N */ ++#define ALIGNMENT_SHIFT 4 + + /* Return the number of bytes in size class I, as a uint. */ + #define INDEX2SIZE(I) (((uint)(I) + 1) << ALIGNMENT_SHIFT) |