From owner-dev-commits-ports-all@freebsd.org Sun May 16 15:28:06 2021 Return-Path: Delivered-To: dev-commits-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 73292645901; Sun, 16 May 2021 15:28:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FjmP22Mx8z4bBR; Sun, 16 May 2021 15:28:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 2C0151B1DC; Sun, 16 May 2021 15:28:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 14GFS684068222; Sun, 16 May 2021 15:28:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 14GFS6jV068221; Sun, 16 May 2021 15:28:06 GMT (envelope-from git) Date: Sun, 16 May 2021 15:28:06 GMT Message-Id: <202105161528.14GFS6jV068221@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: 09397e741e93 - main - lang/python38: Use libmpdec from ports MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 09397e741e930c1354b9feb73b80027268ab4a0f Auto-Submitted: auto-generated X-BeenThere: dev-commits-ports-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the ports repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 May 2021 15:28:06 -0000 The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=09397e741e930c1354b9feb73b80027268ab4a0f commit 09397e741e930c1354b9feb73b80027268ab4a0f Author: Stefan Krah AuthorDate: 2021-05-16 15:19:42 +0000 Commit: Po-Chuan Hsieh CommitDate: 2021-05-16 15:24:46 +0000 lang/python38: Use libmpdec from ports - Bump PORTREVISION for dependency and package change PR: 253603 --- lang/python38/Makefile | 8 ++++++-- .../files/patch-Modules___decimal___decimal.c | 20 ++++++++++++++++++++ lang/python38/files/patch-setup.py | 11 +++++++++++ 3 files changed, 37 insertions(+), 2 deletions(-) diff --git a/lang/python38/Makefile b/lang/python38/Makefile index da6a5bfe9ad1..ecc3e9ca22c1 100644 --- a/lang/python38/Makefile +++ b/lang/python38/Makefile @@ -48,13 +48,14 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${PORTVERSION} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 LIBFFI NLS PYMALLOC -OPTIONS_DEFAULT= LIBFFI PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LIBFFI LIBMPDEC NLS PYMALLOC +OPTIONS_DEFAULT= LIBFFI LIBMPDEC PYMALLOC OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes LIBFFI_DESC= Use libffi from ports instead of bundled version +LIBMPDEC_DESC= Use libmpdec from ports instead of bundled version NLS_DESC= Enable gettext support for the locale module PYMALLOC_DESC= Enable specialized mallocs @@ -71,6 +72,9 @@ IPV6_CONFIGURE_ENABLE= ipv6 LIBFFI_CONFIGURE_ON= --with-system-ffi LIBFFI_LIB_DEPENDS= libffi.so:devel/libffi +LIBMPDEC_CONFIGURE_ON= --with-system-libmpdec +LIBMPDEC_LIB_DEPENDS= libmpdec.so:math/mpdecimal + # Use CPPFLAGS over CFLAGS due to -I ordering, causing elementtree and pyexpat # to break in Python 2.7, or preprocessor complaints in Python >= 3.3 # Upstream Issue: https://bugs.python.org/issue6299 diff --git a/lang/python38/files/patch-Modules___decimal___decimal.c b/lang/python38/files/patch-Modules___decimal___decimal.c new file mode 100644 index 000000000000..4ea7b4f1b4ee --- /dev/null +++ b/lang/python38/files/patch-Modules___decimal___decimal.c @@ -0,0 +1,20 @@ +--- Modules/_decimal/_decimal.c.orig 2021-02-17 20:39:05 UTC ++++ Modules/_decimal/_decimal.c +@@ -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 --git a/lang/python38/files/patch-setup.py b/lang/python38/files/patch-setup.py new file mode 100644 index 000000000000..7bd5deb4202a --- /dev/null +++ b/lang/python38/files/patch-setup.py @@ -0,0 +1,11 @@ +--- setup.py.orig 2021-05-03 09:47:56 UTC ++++ setup.py +@@ -2051,7 +2051,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: