diff options
Diffstat (limited to 'meta/recipes-devtools/qemu/qemu/0011-qemu-Ensure-pip-and-the-python-venv-aren-t-used-for-.patch')
-rw-r--r-- | meta/recipes-devtools/qemu/qemu/0011-qemu-Ensure-pip-and-the-python-venv-aren-t-used-for-.patch | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/meta/recipes-devtools/qemu/qemu/0011-qemu-Ensure-pip-and-the-python-venv-aren-t-used-for-.patch b/meta/recipes-devtools/qemu/qemu/0011-qemu-Ensure-pip-and-the-python-venv-aren-t-used-for-.patch new file mode 100644 index 0000000000..b06020d106 --- /dev/null +++ b/meta/recipes-devtools/qemu/qemu/0011-qemu-Ensure-pip-and-the-python-venv-aren-t-used-for-.patch | |||
@@ -0,0 +1,51 @@ | |||
1 | From 0d85988457a475c25b84085cf090040150a9c16d Mon Sep 17 00:00:00 2001 | ||
2 | From: Richard Purdie <richard.purdie@linuxfoundation.org> | ||
3 | Date: Wed, 22 May 2024 13:58:23 +0200 | ||
4 | Subject: [PATCH] qemu: Ensure pip and the python venv aren't used for meson | ||
5 | |||
6 | Qemu wants to use a supported python version and a specific meson version | ||
7 | to "help" users and uses pip and creates a venv to do this. This is a nightmare | ||
8 | for us. Our versions stay up to date and should be supported so we don't | ||
9 | really need/want this wrapping. Tweak things to disable it. | ||
10 | |||
11 | There was breakage from the wrapper shown by: | ||
12 | |||
13 | bitbake qemu-system-native | ||
14 | <add DISTRO_FEATURES:remove = "opengl" to local.conf> | ||
15 | bitbake qemu-system-native -c configure | ||
16 | |||
17 | which would crash. The issue is the change in configuration removes pieces | ||
18 | from the sysroot but pyc files remainm as do pieces of pip which causes | ||
19 | problems. | ||
20 | |||
21 | Ideally we'd convince upstream to allow some way to disable the venv on | ||
22 | the understanding that if/when it breaks, we keep the pieces. The patch | ||
23 | as it stands is a workaround. | ||
24 | |||
25 | Upstream-Status: Inappropriate [oe specific] | ||
26 | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> | ||
27 | --- | ||
28 | configure | 4 ++-- | ||
29 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
30 | |||
31 | diff --git a/configure b/configure | ||
32 | index 2c5ecd346..5315ede35 100755 | ||
33 | --- a/configure | ||
34 | +++ b/configure | ||
35 | @@ -969,14 +969,14 @@ python="$(command -v "$python")" | ||
36 | echo "python determined to be '$python'" | ||
37 | echo "python version: $($python --version)" | ||
38 | |||
39 | -python="$($python -B "${source_path}/python/scripts/mkvenv.py" create pyvenv)" | ||
40 | +python=python3 | ||
41 | if test "$?" -ne 0 ; then | ||
42 | error_exit "python venv creation failed" | ||
43 | fi | ||
44 | |||
45 | # Suppress writing compiled files | ||
46 | python="$python -B" | ||
47 | -mkvenv="$python ${source_path}/python/scripts/mkvenv.py" | ||
48 | +mkvenv=true | ||
49 | |||
50 | # Finish preparing the virtual environment using vendored .whl files | ||
51 | |||