From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 71697158086 for ; Thu, 18 Nov 2021 05:25:42 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 82808E0882; Thu, 18 Nov 2021 05:25:40 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (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) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DA998E0882 for ; Thu, 18 Nov 2021 05:25:36 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id F0EB7342D5E for ; Thu, 18 Nov 2021 05:25:33 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 54C3E161 for ; Thu, 18 Nov 2021 05:25:32 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1637212970.192068fcd5aa14c681bcd90fe28f4bff641599e1.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/gcc/, sys-devel/gcc/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-devel/gcc/files/gcc-11.2.0-cross-compile-include.patch sys-devel/gcc/gcc-11.2.0.ebuild X-VCS-Directories: sys-devel/gcc/files/ sys-devel/gcc/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 192068fcd5aa14c681bcd90fe28f4bff641599e1 X-VCS-Branch: master Date: Thu, 18 Nov 2021 05:25:32 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 54a6c6b9-8422-4031-bf2b-0d254bc27fc9 X-Archives-Hash: e7bdcdd5dc4091bb740acab44bc0b095 commit: 192068fcd5aa14c681bcd90fe28f4bff641599e1 Author: Sam James gentoo org> AuthorDate: Thu Nov 18 05:22:50 2021 +0000 Commit: Sam James gentoo org> CommitDate: Thu Nov 18 05:22:50 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=192068fc sys-devel/gcc: add workaround for cross-compile failure Bug: https://bugs.gentoo.org/803371 Signed-off-by: Sam James gentoo.org> .../files/gcc-11.2.0-cross-compile-include.patch | 26 ++++++++++++++++++++++ sys-devel/gcc/gcc-11.2.0.ebuild | 9 ++++++++ 2 files changed, 35 insertions(+) diff --git a/sys-devel/gcc/files/gcc-11.2.0-cross-compile-include.patch b/sys-devel/gcc/files/gcc-11.2.0-cross-compile-include.patch new file mode 100644 index 000000000000..d06410650bb0 --- /dev/null +++ b/sys-devel/gcc/files/gcc-11.2.0-cross-compile-include.patch @@ -0,0 +1,26 @@ +https://bugs.gentoo.org/803371 +https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80196 +https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100017 +--- a/configure ++++ b/configure +@@ -17044,7 +17044,7 @@ else + fi + + +-RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET" ++RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET -nostdinc++" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ar" >&5 + $as_echo_n "checking where to find the target ar... " >&6; } +--- a/configure.ac ++++ b/configure.ac +@@ -3529,7 +3529,7 @@ ACX_CHECK_INSTALLED_TARGET_TOOL(STRIP_FOR_TARGET, strip) + ACX_CHECK_INSTALLED_TARGET_TOOL(WINDRES_FOR_TARGET, windres) + ACX_CHECK_INSTALLED_TARGET_TOOL(WINDMC_FOR_TARGET, windmc) + +-RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET" ++RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET -nostdinc++" + + GCC_TARGET_TOOL(ar, AR_FOR_TARGET, AR, [binutils/ar]) + GCC_TARGET_TOOL(as, AS_FOR_TARGET, AS, [gas/as-new]) + diff --git a/sys-devel/gcc/gcc-11.2.0.ebuild b/sys-devel/gcc/gcc-11.2.0.ebuild index 193f8b813ec4..728de92f4777 100644 --- a/sys-devel/gcc/gcc-11.2.0.ebuild +++ b/sys-devel/gcc/gcc-11.2.0.ebuild @@ -11,3 +11,12 @@ KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 RDEPEND="" BDEPEND="${CATEGORY}/binutils" + +src_prepare() { + toolchain_src_prepare + + if is_crosscompile ; then + # bug #803371 + eapply "${FILESDIR}"/gcc-11.2.0-cross-compile-include.patch + fi +}