diff options
author | Josselin Poiret <[email protected]> | 2023-03-21 09:59:37 +0100 |
---|---|---|
committer | Ludovic Courtès <[email protected]> | 2023-03-26 22:19:29 +0200 |
commit | 68793b702e4295d011c89e72826fd15ce18e0b95 (patch) | |
tree | f7d2c02c653cb1e0299fca4c04c5f9eafac7fbeb /gnu/packages/patches/u-boot-fix-build-python-3.10.patch | |
parent | 2a4fa1d127b28b05da08b930456a0c2e44d745c3 (diff) |
gnu: u-boot: Fix build under Python 3.10.
* 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.
Signed-off-by: Ludovic Courtès <[email protected]>
Diffstat (limited to 'gnu/packages/patches/u-boot-fix-build-python-3.10.patch')
-rw-r--r-- | gnu/packages/patches/u-boot-fix-build-python-3.10.patch | 37 |
1 files changed, 37 insertions, 0 deletions
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..7e5d6ba656 --- /dev/null +++ b/gnu/packages/patches/u-boot-fix-build-python-3.10.patch @@ -0,0 +1,37 @@ +This patch is backported from U-Boot 2023.01; remove when updating. + +From 7d01bb1c5a1daef0187c9ea276bde19a8d0e7fde Mon Sep 17 00:00:00 2001 +From: Michal Suchanek <[email protected]> +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 <[email protected]> +Reviewed-by: Simon Glass <[email protected]> +--- + 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 <stdint.i> + + %{ +-- +GitLab + |