Commit 71c7249a authored by Stefan Krah's avatar Stefan Krah Committed by Leo
Browse files

main/python3: build --with-system-libmpdec

parent 85629f25
......@@ -6,7 +6,7 @@ pkgname=python3
pkgver=3.8.7
_bluez_ver=5.54
_basever="${pkgver%.*}"
pkgrel=0
pkgrel=1
pkgdesc="A high-level scripting language"
url="https://www.python.org/"
arch="all"
......@@ -15,13 +15,14 @@ subpackages="$pkgname-dbg $pkgname-dev $pkgname-doc $pkgname-tests::noarch
$pkgname-wininst"
makedepends="expat-dev openssl-dev zlib-dev ncurses-dev bzip2-dev xz-dev
sqlite-dev libffi-dev tcl-dev linux-headers gdbm-dev>=1.18.1-r0 readline-dev
automake autoconf libtool !gettext-dev"
mpdecimal-dev automake autoconf libtool !gettext-dev"
source="https://www.python.org/ftp/python/$pkgver/Python-$pkgver.tar.xz
https://www.kernel.org/pub/linux/bluetooth/bluez-$_bluez_ver.tar.xz
fix-xattrs-glibc.patch
musl-find_library.patch
custom-bluetooth-h-path.patch
arm-alignment.patch
mpdecimal-2.5.1.patch
"
builddir="$srcdir/Python-$pkgver"
......@@ -73,6 +74,7 @@ build() {
--with-dbmliborder=gdbm:ndbm \
--with-system-expat \
--with-system-ffi \
--with-system-libmpdec \
--with-threads \
--without-ensurepip \
--with-bluetoothdir="$srcdir/bluez-$_bluez_ver"
......@@ -186,4 +188,5 @@ e19d15d3a478a7af47c1921c8827843492e38787b1182152155bd3d8ad9e1d8ee25c5fda1f24e38c
37b6ee5d0d5de43799316aa111423ba5a666c17dc7f81b04c330f59c1d1565540eac4c585abe2199bbed52ebe7426001edb1c53bd0a17486a2a8e052d0f494ad fix-xattrs-glibc.patch
ab8eaa2858d5109049b1f9f553198d40e0ef8d78211ad6455f7b491af525bffb16738fed60fc84e960c4889568d25753b9e4a1494834fea48291b33f07000ec2 musl-find_library.patch
d489b5d5f374e2b298954a2388771e500c6cf9b274012e06b3e71a34aa85c354369b3fa2a37c3121808075c1f1f340a9fa097996c149399e10b9424170211d90 custom-bluetooth-h-path.patch
a84483246e413650a904c34c18f5e4f4168c39067d069f48557c330de6eb3db19fd96a4d453d742db3dcb7c7f962722903f62823c752ff90510c89830435ffc0 arm-alignment.patch"
a84483246e413650a904c34c18f5e4f4168c39067d069f48557c330de6eb3db19fd96a4d453d742db3dcb7c7f962722903f62823c752ff90510c89830435ffc0 arm-alignment.patch
d95e36ef3c315a2ddf689c9319e027cf56e8817b0cae139e3ade4742ab6f9efcb3cc4adca178e9bbc8757bd0e3fb924ac2b37e66e70eaa7288202a25339eed7d mpdecimal-2.5.1.patch"
diff -Nurp a-Python-3.8.7/Modules/_decimal/_decimal.c b-Python-3.8.7/Modules/_decimal/_decimal.c
--- a-Python-3.8.7/Modules/_decimal/_decimal.c 2020-12-21 16:25:24.000000000 +0000
+++ b-Python-3.8.7/Modules/_decimal/_decimal.c 2021-02-10 15:45:09.976876631 +0000
@@ -3284,7 +3284,7 @@ dec_format(PyObject *dec, PyObject *args
}
else {
size_t n = strlen(spec.dot);
- if (n > 1 || (n == 1 && !isascii((uchar)spec.dot[0]))) {
+ if (n > 1 || (n == 1 && !isascii((unsigned char)spec.dot[0]))) {
/* fix locale dependent non-ascii characters */
dot = dotsep_as_utf8(spec.dot);
if (dot == NULL) {
@@ -3293,7 +3293,7 @@ dec_format(PyObject *dec, PyObject *args
spec.dot = PyBytes_AS_STRING(dot);
}
n = strlen(spec.sep);
- if (n > 1 || (n == 1 && !isascii((uchar)spec.sep[0]))) {
+ if (n > 1 || (n == 1 && !isascii((unsigned char)spec.sep[0]))) {
/* fix locale dependent non-ascii characters */
sep = dotsep_as_utf8(spec.sep);
if (sep == NULL) {
diff -Nurp a-Python-3.8.7/setup.py b-Python-3.8.7/setup.py
--- a-Python-3.8.7/setup.py 2020-12-21 16:25:24.000000000 +0000
+++ b-Python-3.8.7/setup.py 2021-02-10 15:45:09.977876640 +0000
@@ -2077,7 +2077,7 @@ class PyBuildExt(build_ext):
undef_macros = []
if '--with-system-libmpdec' in sysconfig.get_config_var("CONFIG_ARGS"):
include_dirs = []
- libraries = [':libmpdec.so.2']
+ libraries = ['mpdec']
sources = ['_decimal/_decimal.c']
depends = ['_decimal/docstrings.h']
else:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment