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 464C9158013 for ; Thu, 14 Dec 2023 04:22:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 301FD2BC03C; Thu, 14 Dec 2023 04:22:22 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (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 13BA52BC03C for ; Thu, 14 Dec 2023 04:22:22 +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 EFF4D33EB78 for ; Thu, 14 Dec 2023 04:22:20 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 6954B125F for ; Thu, 14 Dec 2023 04:22:19 +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: <1702527640.42c3c45c2ae81d83676fa8573ee531ae21400fa1.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/cfortran/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-lang/cfortran/cfortran-20210827.ebuild X-VCS-Directories: dev-lang/cfortran/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 42c3c45c2ae81d83676fa8573ee531ae21400fa1 X-VCS-Branch: master Date: Thu, 14 Dec 2023 04:22:19 +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: 3b23d5f5-78bb-4b2c-a0a1-927439d053eb X-Archives-Hash: cc42d5481ee3d6d032d5f21a5a3abf1f commit: 42c3c45c2ae81d83676fa8573ee531ae21400fa1 Author: Matoro Mahri matoro tk> AuthorDate: Wed Dec 6 06:24:05 2023 +0000 Commit: Sam James gentoo org> CommitDate: Thu Dec 14 04:20:40 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=42c3c45c dev-lang/cfortran: add -fcommon to CFLAGS for tests In the failing test, both the Fortran code and the C code have a symbol called _fcb. The test expects it to be in the common section in both objects, such that when it gets linked, they both refer to the same symbol, such that changes on the C side to the variable are reflected on the Fortran side and vice versa. However with -fno-common then it's still placed in the common section in Fortran, but in C it's placed in the BSS section, so now they refer to different objects. The linker actually emits a warning for this, something like "alignment 1 is less than 16". When there are two symbols in different sections with the same name, this is an ODR violation which is UB on all platforms. Bug: https://bugs.gentoo.org/899452 Signed-off-by: Matoro Mahri matoro.tk> Closes: https://github.com/gentoo/gentoo/pull/34143 Signed-off-by: Sam James gentoo.org> dev-lang/cfortran/cfortran-20210827.ebuild | 1 + 1 file changed, 1 insertion(+) diff --git a/dev-lang/cfortran/cfortran-20210827.ebuild b/dev-lang/cfortran/cfortran-20210827.ebuild index feadc03d0c45..d001f52cea3b 100644 --- a/dev-lang/cfortran/cfortran-20210827.ebuild +++ b/dev-lang/cfortran/cfortran-20210827.ebuild @@ -41,6 +41,7 @@ src_prepare() { src_configure() { use sparc && append-fflags $(test-flags-FC -fno-store-merging -fno-tree-slp-vectorize) # bug 818400 + append-cflags $(test-flags-CC -fcommon) # bug 899452 default }