From patchwork Tue Mar 10 11:12:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Efraim Flashner X-Patchwork-Id: 20623 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id AED6727BBEA; Tue, 10 Mar 2020 11:14:20 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 31EC727BBE4 for ; Tue, 10 Mar 2020 11:14:20 +0000 (GMT) Received: from localhost ([::1]:57940 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBcq3-0006NK-Nk for patchwork@mira.cbaines.net; Tue, 10 Mar 2020 07:14:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43242) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBcpn-0006Lz-RW for guix-patches@gnu.org; Tue, 10 Mar 2020 07:14:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jBcpm-0005ye-KL for guix-patches@gnu.org; Tue, 10 Mar 2020 07:14:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:45971) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jBcpm-0005yL-GZ for guix-patches@gnu.org; Tue, 10 Mar 2020 07:14:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jBcpm-0000Uk-CC for guix-patches@gnu.org; Tue, 10 Mar 2020 07:14:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#40009] [core-updates PATCH]: Use per-architecture GCC for libstdc++-boot0 Resent-From: Efraim Flashner Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 10 Mar 2020 11:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 40009 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 40009@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15838388241869 (code B ref -1); Tue, 10 Mar 2020 11:14:02 +0000 Received: (at submit) by debbugs.gnu.org; 10 Mar 2020 11:13:44 +0000 Received: from localhost ([127.0.0.1]:51944 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jBcpO-0000Tx-0m for submit@debbugs.gnu.org; Tue, 10 Mar 2020 07:13:44 -0400 Received: from lists.gnu.org ([209.51.188.17]:45094) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jBcpJ-0000Tn-JF for submit@debbugs.gnu.org; Tue, 10 Mar 2020 07:13:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42230) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBcpI-0005xw-A5 for guix-patches@gnu.org; Tue, 10 Mar 2020 07:13:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jBcpH-0004GF-6P for guix-patches@gnu.org; Tue, 10 Mar 2020 07:13:32 -0400 Received: from flashner.co.il ([178.62.234.194]:52520) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1jBcpG-000375-DC for guix-patches@gnu.org; Tue, 10 Mar 2020 07:13:31 -0400 Received: from localhost (unknown [141.226.13.108]) by flashner.co.il (Postfix) with ESMTPSA id 1261B400E5 for ; Tue, 10 Mar 2020 11:12:58 +0000 (UTC) Date: Tue, 10 Mar 2020 13:12:27 +0200 From: Efraim Flashner Message-ID: <20200310111227.GX1423@E5400> MIME-Version: 1.0 Content-Disposition: inline X-PGP-Key-ID: 0x41AAE7DCCA3D8351 X-PGP-Key: https://flashner.co.il/~efraim/efraim_flashner.asc X-PGP-Fingerprint: A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches I've tested this on aarch64 and there were no problems. It also provides a nice framework for other architectures as they become supported. diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index 2a0a83ad49..b5cb08a19a 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2014 Andreas Enge ;;; Copyright © 2012 Nikita Karetnikov ;;; Copyright © 2014, 2015, 2017 Mark H Weaver -;;; Copyright © 2017, 2018, 2019 Efraim Flashner +;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2018 Tobias Geerinckx-Rice ;;; Copyright © 2018 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2019 Marius Bakke @@ -1427,9 +1427,12 @@ exec " gcc "/bin/" program (define libstdc++-boot0 ;; GCC's libcc1 is always built as a shared library (the top-level ;; 'Makefile.def' forcefully adds --enable-shared) and thus needs to refer - ;; to libstdc++.so. We cannot build libstdc++-5.3 because it relies on - ;; C++14 features missing in some of our bootstrap compilers. - (let ((lib (make-libstdc++ gcc-4.9))) + ;; to libstdc++.so. We therefore use a version of GCC which most closely + ;; matches the bootstrap compiler of that architecture. + (let ((lib (make-libstdc++ + (match (%current-system) + ("aarch64-linux" gcc-5) + (_ gcc-4.9))))) (package (inherit lib) (source (bootstrap-origin (package-source lib)))