From nobody Wed Mar 9 17:35:15 2022 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id F0BDD1A0D1F5; Wed, 9 Mar 2022 17:35:15 +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 4KDK8g6R2Wz4lNy; Wed, 9 Mar 2022 17:35:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646847315; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dmoXO6XSP1BYZ6LXI7yLYQQLVgle6MNzlrWrkNvA37Y=; b=RGYsjN+ykfP/+n2Z8dzOljK3lz1Cyqa0brLE9/tQH6+zo0jNkxK4HVKNHHLZ2XcsnSceR2 chvu/4enCbTtX3FPXDSpmCoS3+5qBYKxb2EOYHEj2R4nX4Ql1oHu6bF0z+/0q181wD7KRR wNqrIG1MT4H6y7rggnbVXyvwinXrZzu23kqOfNMjjRHo/7K2QJcUNWiIrqLkF36uHJHlSa DQynQ6M5v0UbR69F6II0eEm+JZmhD+rm4h9bAk1IMpqw2EGHRSkC1tz2sUOUI7+6MXp3xd 54kJ5mjGcfyelQHp6fBJfd67ylKVt2W5BmE+zRwaaiDI0sHdXlAiHuxb40fiFQ== 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 B8FED151C3; Wed, 9 Mar 2022 17:35:15 +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 229HZFX5093215; Wed, 9 Mar 2022 17:35:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 229HZFxR093214; Wed, 9 Mar 2022 17:35:15 GMT (envelope-from git) Date: Wed, 9 Mar 2022 17:35:15 GMT Message-Id: <202203091735.229HZFxR093214@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Piotr Kubaj Subject: git: 9a31e1b6d3bf - main - lang/python3*: add LTO option and enable by default everywhere except powerpc64 and riscv64 List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pkubaj X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9a31e1b6d3bff1eef9fcd5e72268c238ec5335fb Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646847315; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dmoXO6XSP1BYZ6LXI7yLYQQLVgle6MNzlrWrkNvA37Y=; b=XtiBiJh2imtSLI28fWsfYl5YXnuLHJx6YIqMgtV3p9gO714Wf3dcEVs2QloSwr7YU8yah+ dcXJMxqkQvBCCH7O2FaZcoHXbAWDm6CW7ZlgvVbDiQvgA2Xoh5k/Jji4/OP2kYqzOoW5dr 8s3JoezicsVjZBDZAFvCR9SlS4W87+RXFVnjtvbO46jN7QcfJTJLlVyHuIvCJ9V4TfU5bR amKcAb+5TO+Pvj4N9GUEgQRxfAJfgdfj+ijOKWnX86CjwEnZaidY8h3+3RU/vC350W+KAL 2Vf3juLv95msl7fnIRDGSfXbxy/z57jhO8KuAqLXFtAKufl1W8pPTQ61EQTD9w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1646847315; a=rsa-sha256; cv=none; b=DOUlvVaczT5xlgfYiKYXP7+POhsvTfvqeiJ5WthQbGbIEW0S4U0QO5Dq2qcIE0RhM0ks4k CoopBvaKwAYQQxaoa2YIAfk20NCCWfmCntB17viaddw7JdGy4bJRJTKmw5AQS58TtsRHIC iq+rRW9ZWo0CwBVIE7PvfIs4rwtQx4eykCZajZnQBbxejacA2Z+4olzezIBz1QsAKCEBV/ 2gN/6iEr/WY1kMw7ZRRyP4k/8siK1P2m8fqUkBNf7zijxAdmNrwsMiwdShQZxr3uRpEpEN kbmtxPQ0mmxlv7Oum3mgOhokiFaZC/IA3SL6HjIG8YSCm0k2JpPWq+pMwIQvGw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by pkubaj: URL: https://cgit.FreeBSD.org/ports/commit/?id=9a31e1b6d3bff1eef9fcd5e72268c238ec5335fb commit 9a31e1b6d3bff1eef9fcd5e72268c238ec5335fb Author: Piotr Kubaj AuthorDate: 2022-03-09 17:30:00 +0000 Commit: Piotr Kubaj CommitDate: 2022-03-09 17:30:00 +0000 lang/python3*: add LTO option and enable by default everywhere except powerpc64 and riscv64 PR: 261974 Approved by: python (koobs got his commit bit revoked during review process) --- lang/python310/Makefile | 9 +++++++-- lang/python310/files/patch-configure | 11 +++++++++++ lang/python311/Makefile | 9 +++++++-- lang/python311/files/patch-configure | 11 +++++++++++ lang/python37/Makefile | 10 +++++++--- lang/python37/files/patch-configure | 11 +++++++++++ lang/python38/Makefile | 10 +++++++--- lang/python38/files/patch-configure | 11 +++++++++++ lang/python39/Makefile | 9 +++++++-- lang/python39/files/patch-configure | 11 +++++++++++ 10 files changed, 90 insertions(+), 12 deletions(-) diff --git a/lang/python310/Makefile b/lang/python310/Makefile index 8084d9b8c66a..dd524e80e451 100644 --- a/lang/python310/Makefile +++ b/lang/python310/Makefile @@ -2,6 +2,7 @@ PORTNAME= python DISTVERSION= ${PYTHON_DISTVERSION} +PORTREVISION= 1 CATEGORIES= lang python MASTER_SITES= PYTHON/ftp/python/${DISTVERSION:C/[a-z].*//} PKGNAMESUFFIX= ${PYTHON_SUFFIX} @@ -52,8 +53,10 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${DISTVERSION:C/[a-z].*//} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC NLS PYMALLOC -OPTIONS_DEFAULT= LIBMPDEC PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC LTO NLS PYMALLOC +OPTIONS_DEFAULT= LIBMPDEC LTO PYMALLOC +OPTIONS_EXCLUDE_powerpc64= LTO +OPTIONS_EXCLUDE_riscv64= LTO OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes @@ -75,6 +78,8 @@ IPV6_CONFIGURE_ENABLE= ipv6 LIBMPDEC_CONFIGURE_ON= --with-system-libmpdec LIBMPDEC_LIB_DEPENDS= libmpdec.so:math/mpdecimal +LTO_CONFIGURE_ON= --with-lto + # 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/python310/files/patch-configure b/lang/python310/files/patch-configure new file mode 100644 index 000000000000..c78047439605 --- /dev/null +++ b/lang/python310/files/patch-configure @@ -0,0 +1,11 @@ +--- configure.orig 2022-02-23 19:52:00 UTC ++++ configure +@@ -6625,7 +6625,7 @@ fi + + if test "$Py_LTO" = 'true' ; then + case $CC in +- *clang*) ++ *clang*|cc) + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args. diff --git a/lang/python311/Makefile b/lang/python311/Makefile index 676094889cc5..2cf3cc6bdb44 100644 --- a/lang/python311/Makefile +++ b/lang/python311/Makefile @@ -2,6 +2,7 @@ PORTNAME= python DISTVERSION= ${PYTHON_DISTVERSION} +PORTREVISION= 1 CATEGORIES= lang python MASTER_SITES= PYTHON/ftp/python/${DISTVERSION:C/[a-z].*//} PKGNAMESUFFIX= ${PYTHON_SUFFIX} @@ -52,8 +53,10 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${DISTVERSION:C/[a-z].*//} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC NLS PYMALLOC -OPTIONS_DEFAULT= LIBMPDEC PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC LTO NLS PYMALLOC +OPTIONS_DEFAULT= LIBMPDEC LTO PYMALLOC +OPTIONS_EXCLUDE_powerpc64= LTO +OPTIONS_EXCLUDE_riscv64= LTO OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes @@ -75,6 +78,8 @@ IPV6_CONFIGURE_ENABLE= ipv6 LIBMPDEC_CONFIGURE_ON= --with-system-libmpdec LIBMPDEC_LIB_DEPENDS= libmpdec.so:math/mpdecimal +LTO_CONFIGURE_ON= --with-lto=thin + # 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/python311/files/patch-configure b/lang/python311/files/patch-configure new file mode 100644 index 000000000000..aa89baed8cc0 --- /dev/null +++ b/lang/python311/files/patch-configure @@ -0,0 +1,11 @@ +--- configure.orig 2022-02-23 19:32:58 UTC ++++ configure +@@ -7244,7 +7244,7 @@ fi + + if test "$Py_LTO" = 'true' ; then + case $CC in +- *clang*) ++ *clang*|cc) + LDFLAGS_NOLTO="-fno-lto" + + if test -n "$ac_tool_prefix"; then diff --git a/lang/python37/Makefile b/lang/python37/Makefile index 43de00c66dd0..442732efc459 100644 --- a/lang/python37/Makefile +++ b/lang/python37/Makefile @@ -2,7 +2,7 @@ PORTNAME= python DISTVERSION= ${PYTHON_DISTVERSION} -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= lang python MASTER_SITES= PYTHON/ftp/python/${DISTVERSION} PKGNAMESUFFIX= ${PYTHON_SUFFIX} @@ -49,8 +49,10 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${DISTVERSION} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 NLS PYMALLOC -OPTIONS_DEFAULT= PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LTO NLS PYMALLOC +OPTIONS_DEFAULT= LTO PYMALLOC +OPTIONS_EXCLUDE_powerpc64= LTO +OPTIONS_EXCLUDE_riscv64= LTO OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes @@ -68,6 +70,8 @@ SIPHASH_CONFIGURE_ON= --with-hash-algorithm=siphash24 DEBUG_CONFIGURE_WITH= pydebug IPV6_CONFIGURE_ENABLE= ipv6 +LTO_CONFIGURE_ON= --with-lto + # 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/python37/files/patch-configure b/lang/python37/files/patch-configure new file mode 100644 index 000000000000..c78047439605 --- /dev/null +++ b/lang/python37/files/patch-configure @@ -0,0 +1,11 @@ +--- configure.orig 2022-02-23 19:52:00 UTC ++++ configure +@@ -6625,7 +6625,7 @@ fi + + if test "$Py_LTO" = 'true' ; then + case $CC in +- *clang*) ++ *clang*|cc) + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args. diff --git a/lang/python38/Makefile b/lang/python38/Makefile index 14fa1346d41c..d5a3247abef1 100644 --- a/lang/python38/Makefile +++ b/lang/python38/Makefile @@ -2,7 +2,7 @@ PORTNAME= python DISTVERSION= ${PYTHON_DISTVERSION} -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= lang python MASTER_SITES= PYTHON/ftp/python/${DISTVERSION} PKGNAMESUFFIX= ${PYTHON_SUFFIX} @@ -52,8 +52,10 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${DISTVERSION} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC NLS PYMALLOC -OPTIONS_DEFAULT= LIBMPDEC PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC LTO NLS PYMALLOC +OPTIONS_DEFAULT= LIBMPDEC LTO PYMALLOC +OPTIONS_EXCLUDE_powerpc64= LTO +OPTIONS_EXCLUDE_riscv64= LTO OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes @@ -75,6 +77,8 @@ IPV6_CONFIGURE_ENABLE= ipv6 LIBMPDEC_CONFIGURE_ON= --with-system-libmpdec LIBMPDEC_LIB_DEPENDS= libmpdec.so:math/mpdecimal +LTO_CONFIGURE_ON= --with-lto + # 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-configure b/lang/python38/files/patch-configure new file mode 100644 index 000000000000..c78047439605 --- /dev/null +++ b/lang/python38/files/patch-configure @@ -0,0 +1,11 @@ +--- configure.orig 2022-02-23 19:52:00 UTC ++++ configure +@@ -6625,7 +6625,7 @@ fi + + if test "$Py_LTO" = 'true' ; then + case $CC in +- *clang*) ++ *clang*|cc) + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args. diff --git a/lang/python39/Makefile b/lang/python39/Makefile index 25a7509e4959..8185af11c466 100644 --- a/lang/python39/Makefile +++ b/lang/python39/Makefile @@ -2,6 +2,7 @@ PORTNAME= python DISTVERSION= ${PYTHON_DISTVERSION} +PORTREVISION= 1 CATEGORIES= lang python MASTER_SITES= PYTHON/ftp/python/${DISTVERSION} PKGNAMESUFFIX= ${PYTHON_SUFFIX} @@ -52,8 +53,10 @@ PLIST_SUB= ABI=${ABIFLAGS} \ XYZDOT=${DISTVERSION} \ OSMAJOR=${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} # For plat-freebsd* in pkg-plist. https://bugs.python.org/issue19554 -OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC NLS PYMALLOC -OPTIONS_DEFAULT= LIBMPDEC PYMALLOC +OPTIONS_DEFINE= DEBUG IPV6 LIBMPDEC LTO NLS PYMALLOC +OPTIONS_DEFAULT= LIBMPDEC LTO PYMALLOC +OPTIONS_EXCLUDE_powerpc64= LTO +OPTIONS_EXCLUDE_riscv64= LTO OPTIONS_RADIO= HASH OPTIONS_RADIO_HASH= FNV SIPHASH OPTIONS_SUB= yes @@ -75,6 +78,8 @@ IPV6_CONFIGURE_ENABLE= ipv6 LIBMPDEC_CONFIGURE_ON= --with-system-libmpdec LIBMPDEC_LIB_DEPENDS= libmpdec.so:math/mpdecimal +LTO_CONFIGURE_ON= --with-lto + # 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/python39/files/patch-configure b/lang/python39/files/patch-configure new file mode 100644 index 000000000000..c78047439605 --- /dev/null +++ b/lang/python39/files/patch-configure @@ -0,0 +1,11 @@ +--- configure.orig 2022-02-23 19:52:00 UTC ++++ configure +@@ -6625,7 +6625,7 @@ fi + + if test "$Py_LTO" = 'true' ; then + case $CC in +- *clang*) ++ *clang*|cc) + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args.