From patchwork Tue Mar 21 08:59:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Josselin Poiret X-Patchwork-Id: 48499 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 A122316F49; Tue, 21 Mar 2023 09:00:18 +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=0.2 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, FROM_SUSPICIOUS_NTLD,MAILING_LIST_MULTI,PDS_OTHER_BAD_TLD, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED autolearn=no 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 12DD016F1D for ; Tue, 21 Mar 2023 09:00:18 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1peXqg-0007p6-0B; Tue, 21 Mar 2023 05:00:06 -0400 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 1peXqe-0007o5-2X for guix-patches@gnu.org; Tue, 21 Mar 2023 05:00:04 -0400 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 1peXqd-0000wx-Hv for guix-patches@gnu.org; Tue, 21 Mar 2023 05:00:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1peXqd-0001cU-9D for guix-patches@gnu.org; Tue, 21 Mar 2023 05:00:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#62309] [PATCH core-updates v2 2/2] u-boot: Fix build under Python 3.10. Resent-From: Josselin Poiret Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 21 Mar 2023 09:00:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62309 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer , Josselin Poiret Cc: 62309@debbugs.gnu.org Received: via spool by 62309-submit@debbugs.gnu.org id=B62309.16793891896162 (code B ref 62309); Tue, 21 Mar 2023 09:00:03 +0000 Received: (at 62309) by debbugs.gnu.org; 21 Mar 2023 08:59:49 +0000 Received: from localhost ([127.0.0.1]:57611 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1peXqP-0001bF-05 for submit@debbugs.gnu.org; Tue, 21 Mar 2023 04:59:49 -0400 Received: from jpoiret.xyz ([206.189.101.64]:35252) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1peXqL-0001av-Gv for 62309@debbugs.gnu.org; Tue, 21 Mar 2023 04:59:46 -0400 Received: from authenticated-user (jpoiret.xyz [206.189.101.64]) by jpoiret.xyz (Postfix) with ESMTPA id 4262C184D43; Tue, 21 Mar 2023 08:59:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpoiret.xyz; s=dkim; t=1679389184; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EeTAa/8d248dqmpYxbBHTGfvbN1E1GMvOm3pRsrhpuY=; b=tkJ5tsVeqY63z9GLON9tt1J2CN296dAx+7tOcCXuvRF1Kcps442PFnN1KyF0mfHlSOtpFn 9u3p1eiQ8kMrr/pIoT6kwIVoSdXgpljHHcC5QAwyy+/k2wya7J84ulyA8sC+UsUARqp9cV /pIYdLgGe+CFq15aY1nCbaJOIpp5Kb7PYBPQYLT16d7k3mv6xjKBjWxc6QhgEntwYdIzp3 8hSHr63jQkeSDThv/xTSnBpP/1job/6Hold7OSEWwh11o2Mhg8YqaasyXVig/UkavUc7hc TOS2DDUAhumX17ArjfAb+nhWY/WUuzwQj5WfVOdZCYNFY3VdsBrX90wBE6xUCg== Date: Tue, 21 Mar 2023 09:59:37 +0100 Message-Id: <1896443a4ab3038fdbd1077a625178eeae1f737b.1679389017.git.dev@jpoiret.xyz> In-Reply-To: References: MIME-Version: 1.0 Authentication-Results: jpoiret.xyz; auth=pass smtp.auth=jpoiret@jpoiret.xyz smtp.mailfrom=dev@jpoiret.xyz X-Spamd-Bar: / 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: , Reply-to: Josselin Poiret X-ACL-Warn: , Josselin Poiret via Guix-patches X-Patchwork-Original-From: Josselin Poiret via Guix-patches via From: Josselin Poiret 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 * gnu/packages/patches/u-boot-fix-build-python-3.10.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. * gnu/packages/bootloaders.scm (u-boot): Apply patch. --- gnu/local.mk | 1 + gnu/packages/bootloaders.scm | 3 ++ .../u-boot-fix-build-python-3.10.patch | 35 +++++++++++++++++++ 3 files changed, 39 insertions(+) create mode 100644 gnu/packages/patches/u-boot-fix-build-python-3.10.patch diff --git a/gnu/local.mk b/gnu/local.mk index 058b23c683..73cf7b89a1 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1936,6 +1936,7 @@ dist_patch_DATA = \ %D%/packages/patches/tuxpaint-stamps-path.patch \ %D%/packages/patches/twinkle-bcg729.patch \ %D%/packages/patches/u-boot-allow-disabling-openssl.patch \ + %D%/packages/patches/u-boot-fix-build-python-3.10.patch \ %D%/packages/patches/u-boot-infodocs-target.patch \ %D%/packages/patches/u-boot-patman-guix-integration.patch \ %D%/packages/patches/u-boot-nintendo-nes-serial.patch \ diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index ac269807be..457f3b3994 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -655,6 +655,9 @@ (define u-boot %u-boot-allow-disabling-openssl-patch %u-boot-sifive-prevent-relocating-initrd-fdt %u-boot-rk3399-enable-emmc-phy-patch + ;; FIXME The following patch is backported from 2023.01, + ;; remove when updating. + (search-patch "u-boot-fix-build-python-3.10.patch") (search-patch "u-boot-infodocs-target.patch") (search-patch "u-boot-patman-guix-integration.patch"))) (method url-fetch) diff --git a/gnu/packages/patches/u-boot-fix-build-python-3.10.patch b/gnu/packages/patches/u-boot-fix-build-python-3.10.patch new file mode 100644 index 0000000000..27c03f92f4 --- /dev/null +++ b/gnu/packages/patches/u-boot-fix-build-python-3.10.patch @@ -0,0 +1,35 @@ +From 7d01bb1c5a1daef0187c9ea276bde19a8d0e7fde Mon Sep 17 00:00:00 2001 +From: Michal Suchanek +Date: Thu, 13 Oct 2022 22:43:41 +0200 +Subject: [PATCH] libfdt: Fix build with python 3.10 + +Python 3.10 requires defining PY_SSIZE_T_CLEAN. This will be fixed in +swig 4.10 but it is not clear when it will be released. There was a +warning since python 3.8. + +Link: https://github.com/swig/swig/pull/2277 + +Signed-off-by: Michal Suchanek +Reviewed-by: Simon Glass +--- + scripts/dtc/pylibfdt/libfdt.i_shipped | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/scripts/dtc/pylibfdt/libfdt.i_shipped b/scripts/dtc/pylibfdt/libfdt.i_shipped +index 27c29ea260..56cc5d48f4 100644 +--- a/scripts/dtc/pylibfdt/libfdt.i_shipped ++++ b/scripts/dtc/pylibfdt/libfdt.i_shipped +@@ -7,6 +7,10 @@ + + %module libfdt + ++%begin %{ ++#define PY_SSIZE_T_CLEAN ++%} ++ + %include + + %{ +-- +GitLab +