From patchwork Sat Jan 28 12:57:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Simon South X-Patchwork-Id: 1229 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 1741027BBEB; Sat, 28 Jan 2023 12:58:36 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3658827BBE9 for ; Sat, 28 Jan 2023 12:58:33 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pLkmY-0003az-EG; Sat, 28 Jan 2023 07:58:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pLkmR-0003WF-19 for guix-patches@gnu.org; Sat, 28 Jan 2023 07:58:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pLkmQ-0004vC-N0 for guix-patches@gnu.org; Sat, 28 Jan 2023 07:58:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pLkmQ-0004C7-I6 for guix-patches@gnu.org; Sat, 28 Jan 2023 07:58:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#61119] [PATCH core-updates 0/1] gnu: p7zip: Fix build with GCC 11. Resent-From: Simon South Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 28 Jan 2023 12:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 61119 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 61119@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.167491067016096 (code B ref -1); Sat, 28 Jan 2023 12:58:02 +0000 Received: (at submit) by debbugs.gnu.org; 28 Jan 2023 12:57:50 +0000 Received: from localhost ([127.0.0.1]:39836 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLkmD-0004BW-MZ for submit@debbugs.gnu.org; Sat, 28 Jan 2023 07:57:50 -0500 Received: from lists.gnu.org ([209.51.188.17]:35174) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLkmB-0004BH-CE for submit@debbugs.gnu.org; Sat, 28 Jan 2023 07:57:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pLkmB-0003TH-1r for guix-patches@gnu.org; Sat, 28 Jan 2023 07:57:47 -0500 Received: from mailout.easymail.ca ([64.68.200.34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pLkm9-0004pn-1i for guix-patches@gnu.org; Sat, 28 Jan 2023 07:57:46 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 37BF667B2F for ; Sat, 28 Jan 2023 12:57:40 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo09-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo09-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eB5sKCguarMj for ; Sat, 28 Jan 2023 12:57:40 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id E6F796722C for ; Sat, 28 Jan 2023 12:57:39 +0000 (UTC) From: Simon South Date: Sat, 28 Jan 2023 07:57:37 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 Received-SPF: pass client-ip=64.68.200.34; envelope-from=simon@simonsouth.net; helo=mailout.easymail.ca X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, 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+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches On core-updates, p7zip is failing to build with error messages like ../../../../CPP/7zip/Archive/Wim/WimHandler.cpp:308:11: error: use of an operand of type ‘bool’ in ‘operator++’ is forbidden in C++17 308 | numMethods++; | ^~~~~~~~~~ This follows from the move to GCC 11 and its use by default of the GNU dialect of the C++17 standard for interpreting C++ code. (Note p7zip is essentially abandoned and its code is aging.) The patch to follow causes GCC to use the GNU dialect of the C++14 standard instead, as GCC 10 did by default, reducing the error messages to warnings and allowing the build to complete. I've tested this on x86-64 and AArch64 and everything seems fine. --- Simon South simon@simonsouth.net Simon South (1): gnu: p7zip: Fix build with GCC 11. gnu/local.mk | 1 + gnu/packages/compression.scm | 1 + .../patches/p7zip-fix-build-with-gcc-11.patch | 49 +++++++++++++++++++ 3 files changed, 51 insertions(+) create mode 100644 gnu/packages/patches/p7zip-fix-build-with-gcc-11.patch base-commit: 770d379d7b60590bfdcb749287cb6713dee093ce prerequisite-patch-id: 418e6f2f834e0f77d4da64e48bf654d610fbfe80