diff options
Diffstat (limited to 'meta/recipes-devtools/meson/meson')
-rw-r--r-- | meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch b/meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch index 86abfa9d52..f01a667818 100644 --- a/meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch +++ b/meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From dd5b4a200cd2fdf7fef627c4b6752f90c00b863a Mon Sep 17 00:00:00 2001 | 1 | From 2e9582167bf9d3273004edb2637310531f0155ab Mon Sep 17 00:00:00 2001 |
2 | From: Alexander Kanavin <alex.kanavin@gmail.com> | 2 | From: Alexander Kanavin <alex.kanavin@gmail.com> |
3 | Date: Mon, 19 Nov 2018 14:24:26 +0100 | 3 | Date: Mon, 19 Nov 2018 14:24:26 +0100 |
4 | Subject: [PATCH] python module: do not manipulate the environment when calling | 4 | Subject: [PATCH] python module: do not manipulate the environment when calling |
@@ -8,25 +8,24 @@ Upstream-Status: Inappropriate [oe-core specific] | |||
8 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | 8 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> |
9 | 9 | ||
10 | --- | 10 | --- |
11 | mesonbuild/modules/python.py | 7 +------ | 11 | mesonbuild/modules/python.py | 6 +----- |
12 | 1 file changed, 1 insertion(+), 6 deletions(-) | 12 | 1 file changed, 1 insertion(+), 5 deletions(-) |
13 | 13 | ||
14 | diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py | 14 | diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py |
15 | index f479ab9..b934bc6 100644 | 15 | index 3bbccd1..fda7a25 100644 |
16 | --- a/mesonbuild/modules/python.py | 16 | --- a/mesonbuild/modules/python.py |
17 | +++ b/mesonbuild/modules/python.py | 17 | +++ b/mesonbuild/modules/python.py |
18 | @@ -239,10 +239,6 @@ def python_factory(env: 'Environment', for_machine: 'MachineChoice', | 18 | @@ -277,9 +277,6 @@ def python_factory(env: 'Environment', for_machine: 'MachineChoice', |
19 | # If python-X.Y.pc exists in LIBPC, we will try to use it | 19 | # there is no LIBPC, so we can't search in it |
20 | def wrap_in_pythons_pc_dir(name: str, env: 'Environment', kwargs: T.Dict[str, T.Any], | 20 | return NotFoundDependency('python', env) |
21 | installation: 'PythonInstallation') -> 'ExternalDependency': | 21 | |
22 | - old_pkg_libdir = os.environ.pop('PKG_CONFIG_LIBDIR', None) | 22 | - old_pkg_libdir = os.environ.pop('PKG_CONFIG_LIBDIR', None) |
23 | - old_pkg_path = os.environ.pop('PKG_CONFIG_PATH', None) | 23 | - old_pkg_path = os.environ.pop('PKG_CONFIG_PATH', None) |
24 | - if pkg_libdir: | 24 | - os.environ['PKG_CONFIG_LIBDIR'] = pkg_libdir |
25 | - os.environ['PKG_CONFIG_LIBDIR'] = pkg_libdir | ||
26 | try: | 25 | try: |
27 | return PythonPkgConfigDependency(name, env, kwargs, installation) | 26 | return PythonPkgConfigDependency(name, env, kwargs, installation, True) |
28 | finally: | 27 | finally: |
29 | @@ -251,8 +247,7 @@ def python_factory(env: 'Environment', for_machine: 'MachineChoice', | 28 | @@ -288,8 +285,7 @@ def python_factory(env: 'Environment', for_machine: 'MachineChoice', |
30 | os.environ[name] = value | 29 | os.environ[name] = value |
31 | elif name in os.environ: | 30 | elif name in os.environ: |
32 | del os.environ[name] | 31 | del os.environ[name] |
@@ -34,5 +33,5 @@ index f479ab9..b934bc6 100644 | |||
34 | - set_env('PKG_CONFIG_PATH', old_pkg_path) | 33 | - set_env('PKG_CONFIG_PATH', old_pkg_path) |
35 | + pass | 34 | + pass |
36 | 35 | ||
37 | candidates.extend([ | 36 | candidates.append(functools.partial(wrap_in_pythons_pc_dir, pkg_name, env, kwargs, installation)) |
38 | functools.partial(wrap_in_pythons_pc_dir, pkg_name, env, kwargs, installation), | 37 | # We only need to check both, if a python install has a LIBPC. It might point to the wrong location, |