mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
extra/python to 3.9.1-2
This commit is contained in:
parent
699166521e
commit
ccdd05b0f1
2 changed files with 61 additions and 4 deletions
|
@ -14,7 +14,7 @@ shopt -s extglob
|
|||
pkgbase=python
|
||||
pkgname=(python python-tests)
|
||||
pkgver=3.9.1
|
||||
pkgrel=1
|
||||
pkgrel=2
|
||||
_pybasever=${pkgver%.*}
|
||||
pkgdesc="Next generation of the python high-level scripting language"
|
||||
arch=('x86_64')
|
||||
|
@ -22,15 +22,25 @@ license=('custom')
|
|||
url="https://www.python.org/"
|
||||
depends=('bzip2' 'expat' 'gdbm' 'libffi' 'libnsl' 'libxcrypt' 'openssl' 'zlib')
|
||||
makedepends=('tk' 'sqlite' 'bluez-libs' 'mpdecimal' 'llvm' 'gdb' 'xorg-server-xvfb' 'ttf-font')
|
||||
source=("https://www.python.org/ftp/python/${pkgver%rc*}/Python-${pkgver}.tar.xz"{,.asc})
|
||||
source=("https://www.python.org/ftp/python/${pkgver%rc*}/Python-${pkgver}.tar.xz"{,.asc}
|
||||
mpdecimal-2.5.1.patch
|
||||
bpo-42794.patch::https://github.com/python/cpython/commit/b20d5e5ce95248e0fa77c5d7bf8f6f5b1231fa53.patch)
|
||||
sha512sums=('b90029d6825751685983e9dcf0e0ec9e46f18e6c7d37b0dd7a245a94316f8c0090308ad7c2b2b49ed2514b0b909177231dd5bcad03031bf4624e37136fcf8019'
|
||||
'SKIP')
|
||||
'SKIP'
|
||||
'58f683cbfdc6aa84c03d068c1bc2f1d8d2c17ba4f7b632c14ab1d529d8332e767354266c3815e239427497fff1a42ec2a37739ea312d24cb76a69dcf1c98c0ad'
|
||||
'948f9c16e772a2f4c37f29e5b1d51da5fa10ae0f6701f2698f6e9dffe2f133431ec90f8e2223062a6691810e3b3a99449bf573e3f90e426b8a328a06f6094338')
|
||||
validpgpkeys=('0D96DF4D4110E5C43FBFB17F2D347EA6AA65421D' # Ned Deily (Python release signing key) <nad@python.org>
|
||||
'E3FF2839C048B25C084DEBE9B26995E310250568') # Łukasz Langa (GPG langa.pl) <lukasz@langa.pl>
|
||||
|
||||
prepare() {
|
||||
cd Python-${pkgver}
|
||||
|
||||
patch -p1 -i ../mpdecimal-2.5.1.patch
|
||||
patch -p1 -i ../bpo-42794.patch
|
||||
|
||||
# https://bugs.python.org/issue41346
|
||||
sed -i 's/-j0 //' Makefile.pre.in
|
||||
|
||||
# FS#23997
|
||||
sed -i -e "s|^#.* /usr/local/bin/python|#!/usr/bin/python|" Lib/cgi.py
|
||||
|
||||
|
@ -75,6 +85,8 @@ build() {
|
|||
}
|
||||
|
||||
check() {
|
||||
# test_tk and test_ttk_guionly: https://bugs.python.org/issue43139
|
||||
|
||||
cd Python-${pkgver}
|
||||
|
||||
# Obtain next free server number for xvfb-run; this even works in a chroot environment.
|
||||
|
@ -83,7 +95,7 @@ check() {
|
|||
|
||||
LD_LIBRARY_PATH="${srcdir}/Python-${pkgver}":${LD_LIBRARY_PATH} \
|
||||
LC_CTYPE=en_US.UTF-8 xvfb-run -s "-screen 0 1920x1080x16 -ac +extension GLX" -a -n "$servernum" \
|
||||
"${srcdir}/Python-${pkgver}/python" -m test.regrtest -v -uall
|
||||
"${srcdir}/Python-${pkgver}/python" -m test.regrtest -v -uall -x test_tk -x test_ttk_guionly
|
||||
}
|
||||
|
||||
package_python() {
|
||||
|
|
45
extra/python/mpdecimal-2.5.1.patch
Normal file
45
extra/python/mpdecimal-2.5.1.patch
Normal file
|
@ -0,0 +1,45 @@
|
|||
From dd436be488bdca2123d12d1e148d85cb6f98be5f Mon Sep 17 00:00:00 2001
|
||||
From: Stefan Krah <skrah@bytereef.org>
|
||||
Date: Sun, 10 Jan 2021 16:35:48 +0100
|
||||
Subject: [PATCH] Portability fixes.
|
||||
|
||||
---
|
||||
Modules/_decimal/_decimal.c | 4 ++--
|
||||
setup.py | 2 +-
|
||||
2 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/Modules/_decimal/_decimal.c b/Modules/_decimal/_decimal.c
|
||||
index 664d45a90481d..bbd540bc376e2 100644
|
||||
--- a/Modules/_decimal/_decimal.c
|
||||
+++ b/Modules/_decimal/_decimal.c
|
||||
@@ -3295,7 +3295,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) {
|
||||
@@ -3304,7 +3304,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 --git a/setup.py b/setup.py
|
||||
index ddc0bd067d4e4..c547a68664e8c 100644
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -2199,7 +2199,7 @@ def detect_decimal(self):
|
||||
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:
|
Loading…
Reference in a new issue