From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id zHqwGB7eCmGeUQAAgWs5BA (envelope-from ) for ; Wed, 04 Aug 2021 20:36:14 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id wNHIEx7eCmFXYQAA1q6Kng (envelope-from ) for ; Wed, 04 Aug 2021 18:36:14 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E3A721B5E3 for ; Wed, 4 Aug 2021 20:36:13 +0200 (CEST) Received: from localhost ([::1]:55064 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mBLkS-0004hq-Vd for larch@yhetil.org; Wed, 04 Aug 2021 14:36:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56136) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mBLkI-0004d2-OS for guix-patches@gnu.org; Wed, 04 Aug 2021 14:36:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:33567) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mBLkI-0007hk-HA for guix-patches@gnu.org; Wed, 04 Aug 2021 14:36:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mBLkI-0004rF-B4 for guix-patches@gnu.org; Wed, 04 Aug 2021 14:36:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49880] [PATCH 1/2] gnu: gmp-boot: Fix build on powerpc64le-linux Resent-From: Thiago Jung Bauermann Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 04 Aug 2021 18:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 49880 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 49880@debbugs.gnu.org Cc: Thiago Jung Bauermann X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.162810212418603 (code B ref -1); Wed, 04 Aug 2021 18:36:02 +0000 Received: (at submit) by debbugs.gnu.org; 4 Aug 2021 18:35:24 +0000 Received: from localhost ([127.0.0.1]:45108 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBLjf-0004pz-LJ for submit@debbugs.gnu.org; Wed, 04 Aug 2021 14:35:23 -0400 Received: from lists.gnu.org ([209.51.188.17]:41736) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBLjd-0004pq-BQ for submit@debbugs.gnu.org; Wed, 04 Aug 2021 14:35:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55954) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mBLjc-00045u-2p for guix-patches@gnu.org; Wed, 04 Aug 2021 14:35:20 -0400 Received: from mx.kolabnow.com ([95.128.36.41]:38576) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mBLjY-0006zY-8g for guix-patches@gnu.org; Wed, 04 Aug 2021 14:35:19 -0400 Received: from localhost (unknown [127.0.0.1]) by ext-mx-out002.mykolab.com (Postfix) with ESMTP id 01D7C874 for ; Wed, 4 Aug 2021 20:35:10 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kolabnow.com; h= content-transfer-encoding:content-type:content-type:mime-version :message-id:date:date:subject:subject:from:from:received :received:received; s=dkim20160331; t=1628102110; x=1629916511; bh=OWm3E8mo57bxrWVNvTtfxAjxx4dbrL0Giv57No/c5mE=; b=OIiqvdmJLSFI LbaAdQ2dShngEc7H5MSThDb50TU84Ut9JALxUtc8c0vDnaLxei0eh0k92D7R0bil 7TPRADco1Og9WqLUv/KOMkpcUKJctxnNQWRl3CzosL/l9mJQlnLEiqSFZ/2IyjgU nIuFaLcFAdBfBm+Oss3+FbsOjFTelq/FAmkgauzRbXjS2onbfkGjvYiO+acz2toj c6vAFWm6Pbt0rsp8c1pLigpRu8cwqyHlA4vbl2XQSiNeaX4QM2jYCiqcEPozOPNQ apqT6pa+bj7ms+HRR0JrNq41U4hmFxocs4vnqbYSJ/sq9+H1QCpQXd1U3CzJZVLw ZpeqL75b+cELWrlL4MsD9qxVhgNNWY4sLYb0uR3hm2znX0ihRIEJkAiceFcdZ7XG eVItftSvP+I3p99Gzch+6R9sAcRXKNLmhfaGBvY0Q650VYjUWHOguTOCY0iUpnvw 9XTbUW+c7vxDxioTYl/tDcHh97DRt2jcGCMk+HVpb8w0XPr0rso21DJKeZ8LcaIN Af9wL2TQfUHo6hsMaEroSvkbNyamL/lnjCLapIfbnf4N6WeANPHYlc5r+WwNXjtr 0A8YKjRHBNHhGcj77bbSJ9IuqhCsl6Lz9p9LDKJGV3P1m7CXaxsRc9qLL10eRXn6 dfsx117U7PzpC6/5lEYf2Vx/fr6MChY= X-Virus-Scanned: amavisd-new at mykolab.com Received: from mx.kolabnow.com ([127.0.0.1]) by localhost (ext-mx-out002.mykolab.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zFHF0-1TSCRm for ; Wed, 4 Aug 2021 20:35:10 +0200 (CEST) Received: from int-mx002.mykolab.com (unknown [10.9.13.2]) by ext-mx-out002.mykolab.com (Postfix) with ESMTPS id 6B96A49A for ; Wed, 4 Aug 2021 20:35:09 +0200 (CEST) Received: from ext-subm003.mykolab.com (unknown [10.9.6.3]) by int-mx002.mykolab.com (Postfix) with ESMTPS id 71A6657F4; Wed, 4 Aug 2021 20:35:08 +0200 (CEST) Date: Wed, 4 Aug 2021 15:34:54 -0300 Message-Id: <20210804183454.153783-1-bauermann@kolabnow.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=95.128.36.41; envelope-from=bauermann@kolabnow.com; helo=mx.kolabnow.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" Reply-to: Thiago Jung Bauermann X-ACL-Warn: , Thiago Jung Bauermann via Guix-patches From: Thiago Jung Bauermann via Guix-patches via X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1628102174; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=OWm3E8mo57bxrWVNvTtfxAjxx4dbrL0Giv57No/c5mE=; b=lqroxEUs8FOeOq3Zp7jd59PRimZ1vSpb+bzkPwijpMAz63v1CMPcEFab2LNkKdgJN1wiMN OmfJi61qJe7BMN+kJnLv1ujxH5xvQNZvNtUllMAaOztAeHN9o9wrV4wSWblv4kox7w9nUm Mgge32GZhEVeujQa4dm+D0CiHYAn5E0XlqqrZohI4r/6Q51FGd/Ns6ts1BcsX5eGTktJ97 AKYIanS24ecJcXGlRyaegZ71klcZmzHVXFdBqtREgkGg5z7MnXy0IebM2LFlcNRfrXHF65 uYLohIosdvX0/Y2jpe/s0Nfs38NiWagGVbsGE3q42gat8WTEFGNo4wGsxtzO/Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1628102174; a=rsa-sha256; cv=none; b=O8eaVLOedG34oWhWLfh4kcqlX505NTHYAogdfAtY2sWoHjSHcP8Mq6WriKO3NlRs13lOgr hr9+SQql1pNjtDkWtBNtn2RWdUtNYn6JtcAh7k/mNWm94wUjXscm4XBsSAhFxahvwZxf/O yCAfZuclQfj21b9p0NdwwJ32niD14n9/NIST/nVedr9QjAuY2ZP7lFKFFRmfq38GdH3uvK hxZ6rmudT2sjfVsxs42d5psRMrXIJUDaLPqg40s3aKDxHon9bUh3iHoi+shdDZx1owilnS tskB+QF8HiQFLJTZgv/cAy9YmV11UglWIzIIm34wNsQt3JW10b2D2xyAKESmLQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=kolabnow.com header.s=dkim20160331 header.b=OIiqvdmJ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.41 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=kolabnow.com header.s=dkim20160331 header.b=OIiqvdmJ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: E3A721B5E3 X-Spam-Score: -1.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: 4SQuNvRLXmf0 Linux on powerpc64 used to run in big-endian mode only. When support for little-endian mode was added around 2014, they took the opportunity to update the ELF ABI. The new ABI is known as ELF ABI v2, and the old one retroactively called ELF ABI v1. GMP 4.3.2 was released in 2010, so its hand-optimized assembly code for powerpc64 only support ELF ABI v1. This causes a build failure on powerpc64le-linux, which can be fixed by passing a host triplet with the “none” CPU type. This tells the configure script to use generic C code for the build. * gnu/packages/commencement.scm (gmp-boot)[arguments]{#:configure-flags}: Add “--host=none-unknown-linux-gnu” for powerpc64le targets. --- Hello, This patch fixes the following build error on powerpc64le-linux (shown below for one file, but happens on several): ld: mpn/.libs/add_n.o: ABI version 1 is not compatible with ABI version 2 output ld: failed to merge target specific data of file mpn/.libs/add_n.o I started investigating the problem in core-udpates-frozen but the same issue happens in master as well so I suggest comitting it there instead. The patch applies cleanly to both branches. Thanks, Thiago gnu/packages/commencement.scm | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index e7bd6cf002c7..ae3f07bc59ef 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -1840,7 +1840,23 @@ ac_cv_c_float_format='IEEE (little-endian)' (uri (string-append "mirror://gnu/gmp/gmp-" version ".tar.gz")) (sha256 (base32 - "15rwq54fi3s11izas6g985y9jklm3xprfsmym3v1g6xr84bavqvv")))))) + "15rwq54fi3s11izas6g985y9jklm3xprfsmym3v1g6xr84bavqvv")))) + (arguments + (substitute-keyword-arguments (package-arguments gmp) + ((#:configure-flags gmp-configure-flags) + `(cons* ,@(if (string-prefix? "powerpc64le-" (or (%current-target-system) + (%current-system))) + ;; The powerpc64 assembly code in this version of GMP + ;; only supports the ELF ABI v1 but powerpc64le uses ELF + ;; ABI v2, so use the generic C code instead. This is + ;; done by specifying the CPU type as “none”. + ;; + ;; According to the manual, “this will run quite slowly, + ;; but it should be portable and should at least make it + ;; possible to get something running if all else fails.” + '("--host=none-unknown-linux-gnu") + '()) + ,gmp-configure-flags)))))) (define mpfr-boot (package