commit: 337c1cbdae45b58405e96f06077fdd29203e0ad0 Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> AuthorDate: Sun Jan 5 23:18:45 2020 +0000 Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> CommitDate: Sun Jan 5 23:19:48 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=337c1cbd
dev-lang/python: fix build with -flto in CFLAGS Bug: https://bugs.gentoo.org/700012 Package-Manager: Portage-2.3.84_p2, Repoman-2.3.20_p24 Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> dev-lang/python/python-3.8.1.ebuild | 7 ++++++- dev-lang/python/python-3.9.0_alpha2.ebuild | 5 +++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/dev-lang/python/python-3.8.1.ebuild b/dev-lang/python/python-3.8.1.ebuild index a4f20ee1ff5..95709e4c57b 100644 --- a/dev-lang/python/python-3.8.1.ebuild +++ b/dev-lang/python/python-3.8.1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI="7" @@ -110,6 +110,11 @@ src_configure() { use hardened && replace-flags -O3 -O2 fi + # https://bugs.gentoo.org/700012 + if is-flagq -flto; then + append-cflags $(test-flags-CC -ffat-lto-objects) + fi + # Export CXX so it ends up in /usr/lib/python3.X/config/Makefile. tc-export CXX diff --git a/dev-lang/python/python-3.9.0_alpha2.ebuild b/dev-lang/python/python-3.9.0_alpha2.ebuild index 1dea22df2a9..95bfa0ef59d 100644 --- a/dev-lang/python/python-3.9.0_alpha2.ebuild +++ b/dev-lang/python/python-3.9.0_alpha2.ebuild @@ -126,6 +126,11 @@ src_configure() { use hardened && replace-flags -O3 -O2 fi + # https://bugs.gentoo.org/700012 + if is-flagq -flto; then + append-cflags $(test-flags-CC -ffat-lto-objects) + fi + # Export CXX so it ends up in /usr/lib/python3.X/config/Makefile. tc-export CXX