diff options
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-devtools/meson/meson.inc | 11 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch | 18 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch | 8 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0001-python-module-do-not-manipulate-the-environment-when.patch | 14 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch | 10 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0003-native_bindir.patch | 58 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/4e312c19e693a69b0650ce6c8a8903163c959996.patch | 412 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/cross-prop-default.patch | 23 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson_0.58.0.bb (renamed from meta/recipes-devtools/meson/meson_0.57.2.bb) | 0 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/nativesdk-meson_0.58.0.bb (renamed from meta/recipes-devtools/meson/nativesdk-meson_0.57.2.bb) | 0 |
10 files changed, 456 insertions, 98 deletions
diff --git a/meta/recipes-devtools/meson/meson.inc b/meta/recipes-devtools/meson/meson.inc index 10e7d8a1ce..f60381453b 100644 --- a/meta/recipes-devtools/meson/meson.inc +++ b/meta/recipes-devtools/meson/meson.inc | |||
@@ -12,16 +12,13 @@ SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${P | |||
12 | file://0003-native_bindir.patch \ | 12 | file://0003-native_bindir.patch \ |
13 | file://0001-python-module-do-not-manipulate-the-environment-when.patch \ | 13 | file://0001-python-module-do-not-manipulate-the-environment-when.patch \ |
14 | file://disable-rpath-handling.patch \ | 14 | file://disable-rpath-handling.patch \ |
15 | file://cross-prop-default.patch \ | ||
16 | file://0001-modules-python.py-do-not-substitute-python-s-install.patch \ | 15 | file://0001-modules-python.py-do-not-substitute-python-s-install.patch \ |
17 | file://gi-target-dep.patch \ | 16 | file://gi-target-dep.patch \ |
17 | file://0001-Make-CPU-family-warnings-fatal.patch \ | ||
18 | file://0002-Support-building-allarch-recipes-again.patch \ | ||
19 | file://4e312c19e693a69b0650ce6c8a8903163c959996.patch \ | ||
18 | " | 20 | " |
19 | SRC_URI[sha256sum] = "3a83e7b1c5de94fa991ec34d9b198d94f38ed699d3524cb0fdf3b99fd23d4cc5" | 21 | SRC_URI[sha256sum] = "f4820df0bc969c99019fd4af8ca5f136ee94c63d8a5ad67e7eb73bdbc9182fdd" |
20 | |||
21 | SRC_URI_append_class-native = " \ | ||
22 | file://0001-Make-CPU-family-warnings-fatal.patch \ | ||
23 | file://0002-Support-building-allarch-recipes-again.patch \ | ||
24 | " | ||
25 | 22 | ||
26 | UPSTREAM_CHECK_URI = "https://github.com/mesonbuild/meson/releases" | 23 | UPSTREAM_CHECK_URI = "https://github.com/mesonbuild/meson/releases" |
27 | UPSTREAM_CHECK_REGEX = "meson-(?P<pver>\d+(\.\d+)+)\.tar" | 24 | UPSTREAM_CHECK_REGEX = "meson-(?P<pver>\d+(\.\d+)+)\.tar" |
diff --git a/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch b/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch index 300797f9ee..bcccfabd17 100644 --- a/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch +++ b/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch | |||
@@ -1,34 +1,33 @@ | |||
1 | From 198e2de24adf5845e3ba389b533cf43440ee8acb Mon Sep 17 00:00:00 2001 | 1 | From b64032a2eb1fb760f4ffd5b4b666e2433cf80d39 Mon Sep 17 00:00:00 2001 |
2 | From: Ross Burton <ross.burton@intel.com> | 2 | From: Ross Burton <ross.burton@intel.com> |
3 | Date: Tue, 3 Jul 2018 13:59:09 +0100 | 3 | Date: Tue, 3 Jul 2018 13:59:09 +0100 |
4 | Subject: [PATCH] Make CPU family warnings fatal | 4 | Subject: [PATCH 1/2] Make CPU family warnings fatal |
5 | 5 | ||
6 | Upstream-Status: Inappropriate [OE specific] | 6 | Upstream-Status: Inappropriate [OE specific] |
7 | Signed-off-by: Ross Burton <ross.burton@intel.com> | 7 | Signed-off-by: Ross Burton <ross.burton@intel.com> |
8 | |||
9 | --- | 8 | --- |
10 | mesonbuild/envconfig.py | 2 +- | 9 | mesonbuild/envconfig.py | 2 +- |
11 | mesonbuild/environment.py | 4 +--- | 10 | mesonbuild/environment.py | 4 +--- |
12 | 2 files changed, 2 insertions(+), 4 deletions(-) | 11 | 2 files changed, 2 insertions(+), 4 deletions(-) |
13 | 12 | ||
14 | diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py | 13 | diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py |
15 | index ba35d16..2d3c34c 100644 | 14 | index c6a4df3..4d58c91 100644 |
16 | --- a/mesonbuild/envconfig.py | 15 | --- a/mesonbuild/envconfig.py |
17 | +++ b/mesonbuild/envconfig.py | 16 | +++ b/mesonbuild/envconfig.py |
18 | @@ -262,7 +262,7 @@ class MachineInfo: | 17 | @@ -266,7 +266,7 @@ class MachineInfo: |
19 | 18 | ||
20 | cpu_family = literal['cpu_family'] | 19 | cpu_family = literal['cpu_family'] |
21 | if cpu_family not in known_cpu_families: | 20 | if cpu_family not in known_cpu_families: |
22 | - mlog.warning('Unknown CPU family {}, please report this at https://github.com/mesonbuild/meson/issues/new'.format(cpu_family)) | 21 | - mlog.warning(f'Unknown CPU family {cpu_family}, please report this at https://github.com/mesonbuild/meson/issues/new') |
23 | + raise EnvironmentException('Unknown CPU family {}, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.'.format(cpu_family)) | 22 | + raise EnvironmentException('Unknown CPU family {}, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.'.format(cpu_family)) |
24 | 23 | ||
25 | endian = literal['endian'] | 24 | endian = literal['endian'] |
26 | if endian not in ('little', 'big'): | 25 | if endian not in ('little', 'big'): |
27 | diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py | 26 | diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py |
28 | index 756dd81..4d2c2b6 100644 | 27 | index fc9b703..eea8345 100644 |
29 | --- a/mesonbuild/environment.py | 28 | --- a/mesonbuild/environment.py |
30 | +++ b/mesonbuild/environment.py | 29 | +++ b/mesonbuild/environment.py |
31 | @@ -434,9 +434,7 @@ def detect_cpu_family(compilers: CompilersDict) -> str: | 30 | @@ -436,9 +436,7 @@ def detect_cpu_family(compilers: CompilersDict) -> str: |
32 | trial = 'ppc64' | 31 | trial = 'ppc64' |
33 | 32 | ||
34 | if trial not in known_cpu_families: | 33 | if trial not in known_cpu_families: |
@@ -39,3 +38,6 @@ index 756dd81..4d2c2b6 100644 | |||
39 | 38 | ||
40 | return trial | 39 | return trial |
41 | 40 | ||
41 | -- | ||
42 | 2.24.0 | ||
43 | |||
diff --git a/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch b/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch index 471f1500da..ce90e515da 100644 --- a/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch +++ b/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From d3ef01a4208a801acad380a4aaceb6a21f8fa603 Mon Sep 17 00:00:00 2001 | 1 | From 2f9c59e0489e569c5382404667c10f5c200a72ad 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: Fri, 4 Aug 2017 16:16:41 +0300 | 3 | Date: Fri, 4 Aug 2017 16:16:41 +0300 |
4 | Subject: [PATCH] gtkdoc: fix issues that arise when cross-compiling | 4 | Subject: [PATCH] gtkdoc: fix issues that arise when cross-compiling |
@@ -20,11 +20,11 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | |||
20 | 1 file changed, 4 insertions(+) | 20 | 1 file changed, 4 insertions(+) |
21 | 21 | ||
22 | diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py | 22 | diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py |
23 | index bcf77b9..6a4b472 100644 | 23 | index dc2979e..c9ff9bd 100644 |
24 | --- a/mesonbuild/modules/gnome.py | 24 | --- a/mesonbuild/modules/gnome.py |
25 | +++ b/mesonbuild/modules/gnome.py | 25 | +++ b/mesonbuild/modules/gnome.py |
26 | @@ -974,6 +974,10 @@ This will become a hard error in the future.''') | 26 | @@ -1053,6 +1053,10 @@ class GnomeModule(ExtensionModule): |
27 | args.append('--{}={}'.format(program_name, path)) | 27 | args.append(f'--{program_name}={path}') |
28 | if namespace: | 28 | if namespace: |
29 | args.append('--namespace=' + namespace) | 29 | args.append('--namespace=' + namespace) |
30 | + gtkdoc_exe_wrapper = state.environment.properties.host.get('gtkdoc_exe_wrapper', None) | 30 | + gtkdoc_exe_wrapper = state.environment.properties.host.get('gtkdoc_exe_wrapper', None) |
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 eb0e90dbdd..fdadc6869b 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 689e28c49b85311f93f39df70cbee702fc44afb6 Mon Sep 17 00:00:00 2001 | 1 | From 2264e67d7c2c22ca634fd26ea8ada6f0344ab280 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 |
@@ -12,10 +12,10 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | |||
12 | 1 file changed, 12 deletions(-) | 12 | 1 file changed, 12 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 07be318..b770603 100644 | 15 | index 422155b..aaf5844 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 | @@ -71,11 +71,6 @@ class PythonDependency(ExternalDependency): | 18 | @@ -70,11 +70,6 @@ class PythonDependency(ExternalDependency): |
19 | old_pkg_libdir = os.environ.get('PKG_CONFIG_LIBDIR') | 19 | old_pkg_libdir = os.environ.get('PKG_CONFIG_LIBDIR') |
20 | old_pkg_path = os.environ.get('PKG_CONFIG_PATH') | 20 | old_pkg_path = os.environ.get('PKG_CONFIG_PATH') |
21 | 21 | ||
@@ -26,9 +26,9 @@ index 07be318..b770603 100644 | |||
26 | - | 26 | - |
27 | try: | 27 | try: |
28 | self.pkgdep = PkgConfigDependency(pkg_name, environment, kwargs) | 28 | self.pkgdep = PkgConfigDependency(pkg_name, environment, kwargs) |
29 | mlog.debug('Found "{}" via pkgconfig lookup in LIBPC ({})'.format(pkg_name, pkg_libdir)) | 29 | mlog.debug(f'Found "{pkg_name}" via pkgconfig lookup in LIBPC ({pkg_libdir})') |
30 | @@ -84,13 +79,6 @@ class PythonDependency(ExternalDependency): | 30 | @@ -83,13 +78,6 @@ class PythonDependency(ExternalDependency): |
31 | mlog.debug('"{}" could not be found in LIBPC ({})'.format(pkg_name, pkg_libdir)) | 31 | mlog.debug(f'"{pkg_name}" could not be found in LIBPC ({pkg_libdir})') |
32 | mlog.debug(e) | 32 | mlog.debug(e) |
33 | 33 | ||
34 | - if old_pkg_path is not None: | 34 | - if old_pkg_path is not None: |
@@ -39,5 +39,5 @@ index 07be318..b770603 100644 | |||
39 | - else: | 39 | - else: |
40 | - os.environ.pop('PKG_CONFIG_LIBDIR', None) | 40 | - os.environ.pop('PKG_CONFIG_LIBDIR', None) |
41 | else: | 41 | else: |
42 | mlog.debug('"{}" could not be found in LIBPC ({}), this is likely due to a relocated python installation'.format(pkg_name, pkg_libdir)) | 42 | mlog.debug(f'"{pkg_name}" could not be found in LIBPC ({pkg_libdir}), this is likely due to a relocated python installation') |
43 | 43 | ||
diff --git a/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch b/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch index f6175a194c..dcc1ce9c27 100644 --- a/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch +++ b/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch | |||
@@ -1,19 +1,18 @@ | |||
1 | From ac1021a3abf612e8be9b19eecb97062e0c314701 Mon Sep 17 00:00:00 2001 | 1 | From 656bf55fed01df2d2e2ad6d9d9887173cb16b85c Mon Sep 17 00:00:00 2001 |
2 | From: Peter Kjellerstedt <pkj@axis.com> | 2 | From: Peter Kjellerstedt <pkj@axis.com> |
3 | Date: Thu, 26 Jul 2018 16:32:49 +0200 | 3 | Date: Thu, 26 Jul 2018 16:32:49 +0200 |
4 | Subject: [PATCH] Support building allarch recipes again | 4 | Subject: [PATCH 2/2] Support building allarch recipes again |
5 | 5 | ||
6 | This registers "allarch" as a known CPU family. | 6 | This registers "allarch" as a known CPU family. |
7 | 7 | ||
8 | Upstream-Status: Inappropriate [OE specific] | 8 | Upstream-Status: Inappropriate [OE specific] |
9 | Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> | 9 | Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> |
10 | |||
11 | --- | 10 | --- |
12 | mesonbuild/envconfig.py | 1 + | 11 | mesonbuild/envconfig.py | 1 + |
13 | 1 file changed, 1 insertion(+) | 12 | 1 file changed, 1 insertion(+) |
14 | 13 | ||
15 | diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py | 14 | diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py |
16 | index 2d3c34c..b9e7908 100644 | 15 | index 4d58c91..ff01ad1 100644 |
17 | --- a/mesonbuild/envconfig.py | 16 | --- a/mesonbuild/envconfig.py |
18 | +++ b/mesonbuild/envconfig.py | 17 | +++ b/mesonbuild/envconfig.py |
19 | @@ -36,6 +36,7 @@ from pathlib import Path | 18 | @@ -36,6 +36,7 @@ from pathlib import Path |
@@ -24,3 +23,6 @@ index 2d3c34c..b9e7908 100644 | |||
24 | 'aarch64', | 23 | 'aarch64', |
25 | 'alpha', | 24 | 'alpha', |
26 | 'arc', | 25 | 'arc', |
26 | -- | ||
27 | 2.24.0 | ||
28 | |||
diff --git a/meta/recipes-devtools/meson/meson/0003-native_bindir.patch b/meta/recipes-devtools/meson/meson/0003-native_bindir.patch index ed85116c4f..89257b9e05 100644 --- a/meta/recipes-devtools/meson/meson/0003-native_bindir.patch +++ b/meta/recipes-devtools/meson/meson/0003-native_bindir.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From 1546e1f95a119175b7a4e4272a26dd85505e5ede Mon Sep 17 00:00:00 2001 | 1 | From 30e97d4090a3d3f5b7ddcaf27cfa17f3c8c1d462 Mon Sep 17 00:00:00 2001 |
2 | From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> | 2 | From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> |
3 | Date: Wed, 15 Nov 2017 15:05:01 +0100 | 3 | Date: Wed, 15 Nov 2017 15:05:01 +0100 |
4 | Subject: [PATCH] native_bindir | 4 | Subject: [PATCH] native_bindir |
@@ -18,23 +18,22 @@ Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> | |||
18 | 18 | ||
19 | --- | 19 | --- |
20 | mesonbuild/dependencies/base.py | 19 +++++++++++-------- | 20 | mesonbuild/dependencies/base.py | 19 +++++++++++-------- |
21 | mesonbuild/dependencies/ui.py | 6 +++--- | 21 | 1 file changed, 11 insertions(+), 8 deletions(-) |
22 | 2 files changed, 14 insertions(+), 11 deletions(-) | ||
23 | 22 | ||
24 | diff --git a/mesonbuild/dependencies/base.py b/mesonbuild/dependencies/base.py | 23 | diff --git a/mesonbuild/dependencies/base.py b/mesonbuild/dependencies/base.py |
25 | index cd77b4b..7e3f338 100644 | 24 | index 14380d4..d0c443f 100644 |
26 | --- a/mesonbuild/dependencies/base.py | 25 | --- a/mesonbuild/dependencies/base.py |
27 | +++ b/mesonbuild/dependencies/base.py | 26 | +++ b/mesonbuild/dependencies/base.py |
28 | @@ -192,7 +192,7 @@ class Dependency: | 27 | @@ -179,7 +179,7 @@ class Dependency: |
29 | def get_exe_args(self, compiler): | 28 | def get_exe_args(self, compiler): |
30 | return [] | 29 | return [] |
31 | 30 | ||
32 | - def get_pkgconfig_variable(self, variable_name: str, kwargs: T.Dict[str, T.Any]) -> str: | 31 | - def get_pkgconfig_variable(self, variable_name: str, kwargs: T.Dict[str, T.Any]) -> str: |
33 | + def get_pkgconfig_variable(self, variable_name: str, kwargs: T.Dict[str, T.Any], use_native=False) -> str: | 32 | + def get_pkgconfig_variable(self, variable_name: str, kwargs: T.Dict[str, T.Any], use_native=False) -> str: |
34 | raise DependencyException('{!r} is not a pkgconfig dependency'.format(self.name)) | 33 | raise DependencyException(f'{self.name!r} is not a pkgconfig dependency') |
35 | 34 | ||
36 | def get_configtool_variable(self, variable_name): | 35 | def get_configtool_variable(self, variable_name): |
37 | @@ -280,7 +280,7 @@ class InternalDependency(Dependency): | 36 | @@ -267,7 +267,7 @@ class InternalDependency(Dependency): |
38 | return True | 37 | return True |
39 | return any(d.is_built() for d in self.ext_deps) | 38 | return any(d.is_built() for d in self.ext_deps) |
40 | 39 | ||
@@ -43,7 +42,7 @@ index cd77b4b..7e3f338 100644 | |||
43 | raise DependencyException('Method "get_pkgconfig_variable()" is ' | 42 | raise DependencyException('Method "get_pkgconfig_variable()" is ' |
44 | 'invalid for an internal dependency') | 43 | 'invalid for an internal dependency') |
45 | 44 | ||
46 | @@ -658,8 +658,11 @@ class PkgConfigDependency(ExternalDependency): | 45 | @@ -645,8 +645,11 @@ class PkgConfigDependency(ExternalDependency): |
47 | return s.format(self.__class__.__name__, self.name, self.is_found, | 46 | return s.format(self.__class__.__name__, self.name, self.is_found, |
48 | self.version_reqs) | 47 | self.version_reqs) |
49 | 48 | ||
@@ -57,16 +56,16 @@ index cd77b4b..7e3f338 100644 | |||
57 | p, out, err = Popen_safe(cmd, env=env) | 56 | p, out, err = Popen_safe(cmd, env=env) |
58 | rc, out, err = p.returncode, out.strip(), err.strip() | 57 | rc, out, err = p.returncode, out.strip(), err.strip() |
59 | call = ' '.join(cmd) | 58 | call = ' '.join(cmd) |
60 | @@ -685,7 +688,7 @@ class PkgConfigDependency(ExternalDependency): | 59 | @@ -674,7 +677,7 @@ class PkgConfigDependency(ExternalDependency): |
61 | env['PKG_CONFIG_LIBDIR'] = new_pkg_config_libdir | 60 | if key.startswith('PKG_'): |
62 | mlog.debug('PKG_CONFIG_LIBDIR: ' + new_pkg_config_libdir) | 61 | mlog.debug(f'env[{key}]: {value}') |
63 | 62 | ||
64 | - def _call_pkgbin(self, args, env=None): | 63 | - def _call_pkgbin(self, args, env=None): |
65 | + def _call_pkgbin(self, args, env=None, use_native=False): | 64 | + def _call_pkgbin(self, args, env=None, use_native=False): |
66 | # Always copy the environment since we're going to modify it | 65 | # Always copy the environment since we're going to modify it |
67 | # with pkg-config variables | 66 | # with pkg-config variables |
68 | if env is None: | 67 | if env is None: |
69 | @@ -699,7 +702,7 @@ class PkgConfigDependency(ExternalDependency): | 68 | @@ -688,7 +691,7 @@ class PkgConfigDependency(ExternalDependency): |
70 | targs = tuple(args) | 69 | targs = tuple(args) |
71 | cache = PkgConfigDependency.pkgbin_cache | 70 | cache = PkgConfigDependency.pkgbin_cache |
72 | if (self.pkgbin, targs, fenv) not in cache: | 71 | if (self.pkgbin, targs, fenv) not in cache: |
@@ -75,7 +74,7 @@ index cd77b4b..7e3f338 100644 | |||
75 | return cache[(self.pkgbin, targs, fenv)] | 74 | return cache[(self.pkgbin, targs, fenv)] |
76 | 75 | ||
77 | def _convert_mingw_paths(self, args: T.List[str]) -> T.List[str]: | 76 | def _convert_mingw_paths(self, args: T.List[str]) -> T.List[str]: |
78 | @@ -905,7 +908,7 @@ class PkgConfigDependency(ExternalDependency): | 77 | @@ -894,7 +897,7 @@ class PkgConfigDependency(ExternalDependency): |
79 | (self.name, out_raw)) | 78 | (self.name, out_raw)) |
80 | self.link_args, self.raw_link_args = self._search_libs(out, out_raw) | 79 | self.link_args, self.raw_link_args = self._search_libs(out, out_raw) |
81 | 80 | ||
@@ -84,7 +83,7 @@ index cd77b4b..7e3f338 100644 | |||
84 | options = ['--variable=' + variable_name, self.name] | 83 | options = ['--variable=' + variable_name, self.name] |
85 | 84 | ||
86 | if 'define_variable' in kwargs: | 85 | if 'define_variable' in kwargs: |
87 | @@ -918,7 +921,7 @@ class PkgConfigDependency(ExternalDependency): | 86 | @@ -907,7 +910,7 @@ class PkgConfigDependency(ExternalDependency): |
88 | 87 | ||
89 | options = ['--define-variable=' + '='.join(definition)] + options | 88 | options = ['--define-variable=' + '='.join(definition)] + options |
90 | 89 | ||
@@ -93,34 +92,3 @@ index cd77b4b..7e3f338 100644 | |||
93 | variable = '' | 92 | variable = '' |
94 | if ret != 0: | 93 | if ret != 0: |
95 | if self.required: | 94 | if self.required: |
96 | diff --git a/mesonbuild/dependencies/ui.py b/mesonbuild/dependencies/ui.py | ||
97 | index d897d76..a598d2e 100644 | ||
98 | --- a/mesonbuild/dependencies/ui.py | ||
99 | +++ b/mesonbuild/dependencies/ui.py | ||
100 | @@ -325,7 +325,7 @@ class QtBaseDependency(ExternalDependency): | ||
101 | self.bindir = self.get_pkgconfig_host_bins(core) | ||
102 | if not self.bindir: | ||
103 | # If exec_prefix is not defined, the pkg-config file is broken | ||
104 | - prefix = core.get_pkgconfig_variable('exec_prefix', {}) | ||
105 | + prefix = core.get_pkgconfig_variable('exec_prefix', {}, use_native=True) | ||
106 | if prefix: | ||
107 | self.bindir = os.path.join(prefix, 'bin') | ||
108 | |||
109 | @@ -528,7 +528,7 @@ class Qt4Dependency(QtBaseDependency): | ||
110 | applications = ['moc', 'uic', 'rcc', 'lupdate', 'lrelease'] | ||
111 | for application in applications: | ||
112 | try: | ||
113 | - return os.path.dirname(core.get_pkgconfig_variable('%s_location' % application, {})) | ||
114 | + return os.path.dirname(core.get_pkgconfig_variable('%s_location' % application, {}, use_native=True)) | ||
115 | except MesonException: | ||
116 | pass | ||
117 | |||
118 | @@ -538,7 +538,7 @@ class Qt5Dependency(QtBaseDependency): | ||
119 | QtBaseDependency.__init__(self, 'qt5', env, kwargs) | ||
120 | |||
121 | def get_pkgconfig_host_bins(self, core): | ||
122 | - return core.get_pkgconfig_variable('host_bins', {}) | ||
123 | + return core.get_pkgconfig_variable('host_bins', {}, use_native=True) | ||
124 | |||
125 | def get_private_includes(self, mod_inc_dir, module): | ||
126 | return _qt_get_private_includes(mod_inc_dir, module, self.version) | ||
diff --git a/meta/recipes-devtools/meson/meson/4e312c19e693a69b0650ce6c8a8903163c959996.patch b/meta/recipes-devtools/meson/meson/4e312c19e693a69b0650ce6c8a8903163c959996.patch new file mode 100644 index 0000000000..76daf019b0 --- /dev/null +++ b/meta/recipes-devtools/meson/meson/4e312c19e693a69b0650ce6c8a8903163c959996.patch | |||
@@ -0,0 +1,412 @@ | |||
1 | From 4e312c19e693a69b0650ce6c8a8903163c959996 Mon Sep 17 00:00:00 2001 | ||
2 | From: Xavier Claessens <xavier.claessens@collabora.com> | ||
3 | Date: Tue, 11 May 2021 09:18:47 -0400 | ||
4 | Subject: [PATCH] gnome: Fix gtkdoc generation | ||
5 | |||
6 | install_scripts used to replace @BUILD_ROOT@ and @SOURCE_ROOT@ but it | ||
7 | was not documented and got removed in Meson 0.58.0. gnome.gtkdoc() was | ||
8 | relying on that behaviour, but it has always been broken in the case the | ||
9 | source or build directory contains spaces. | ||
10 | |||
11 | Fix this by changing get_include_args() to substitue paths directly | ||
12 | which will then get escaped correctly. | ||
13 | |||
14 | Add a unit test that builds GObject documentation which is where this | ||
15 | issue has been spotted. | ||
16 | |||
17 | Fixes: #8744 | ||
18 | Upstream-Status: Backport | ||
19 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | ||
20 | --- | ||
21 | mesonbuild/modules/__init__.py | 54 +++++++++---------- | ||
22 | mesonbuild/modules/gnome.py | 15 +++--- | ||
23 | mesonbuild/modules/hotdoc.py | 3 +- | ||
24 | mesonbuild/modules/qt.py | 4 +- | ||
25 | mesonbuild/modules/windows.py | 5 +- | ||
26 | .../10 gtk-doc/doc/foobar1/foobar-docs.sgml | 2 +- | ||
27 | .../doc/foobar1/foobar-sections.txt | 16 ++++++ | ||
28 | .../10 gtk-doc/doc/foobar1/foobar.types | 4 ++ | ||
29 | .../10 gtk-doc/doc/foobar1/meson.build | 6 ++- | ||
30 | test cases/frameworks/10 gtk-doc/foo.c | 30 +++++++++++ | ||
31 | .../frameworks/10 gtk-doc/include/foo.h | 18 +++++++ | ||
32 | test cases/frameworks/10 gtk-doc/meson.build | 12 +++++ | ||
33 | test cases/frameworks/10 gtk-doc/test.json | 4 +- | ||
34 | 13 files changed, 127 insertions(+), 46 deletions(-) | ||
35 | create mode 100644 test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-sections.txt | ||
36 | create mode 100644 test cases/frameworks/10 gtk-doc/doc/foobar1/foobar.types | ||
37 | create mode 100644 test cases/frameworks/10 gtk-doc/foo.c | ||
38 | |||
39 | diff --git a/mesonbuild/modules/__init__.py b/mesonbuild/modules/__init__.py | ||
40 | index ddb5e3e6cf3..c0970294c34 100644 | ||
41 | --- a/mesonbuild/modules/__init__.py | ||
42 | +++ b/mesonbuild/modules/__init__.py | ||
43 | @@ -56,6 +56,33 @@ def __init__(self, interpreter: 'Interpreter') -> None: | ||
44 | self.target_machine = interpreter.builtin['target_machine'].held_object | ||
45 | self.current_node = interpreter.current_node | ||
46 | |||
47 | + def get_include_args(self, include_dirs, prefix='-I'): | ||
48 | + if not include_dirs: | ||
49 | + return [] | ||
50 | + | ||
51 | + srcdir = self.environment.get_source_dir() | ||
52 | + builddir = self.environment.get_build_dir() | ||
53 | + | ||
54 | + dirs_str = [] | ||
55 | + for dirs in unholder(include_dirs): | ||
56 | + if isinstance(dirs, str): | ||
57 | + dirs_str += [f'{prefix}{dirs}'] | ||
58 | + continue | ||
59 | + | ||
60 | + # Should be build.IncludeDirs object. | ||
61 | + basedir = dirs.get_curdir() | ||
62 | + for d in dirs.get_incdirs(): | ||
63 | + expdir = os.path.join(basedir, d) | ||
64 | + srctreedir = os.path.join(srcdir, expdir) | ||
65 | + buildtreedir = os.path.join(builddir, expdir) | ||
66 | + dirs_str += [f'{prefix}{buildtreedir}', | ||
67 | + f'{prefix}{srctreedir}'] | ||
68 | + for d in dirs.get_extra_build_dirs(): | ||
69 | + dirs_str += [f'{prefix}{d}'] | ||
70 | + | ||
71 | + return dirs_str | ||
72 | + | ||
73 | + | ||
74 | class ModuleObject: | ||
75 | """Base class for all objects returned by modules | ||
76 | """ | ||
77 | @@ -71,33 +98,6 @@ def __init__(self, interpreter: T.Optional['Interpreter'] = None) -> None: | ||
78 | class ExtensionModule(ModuleObject): | ||
79 | pass | ||
80 | |||
81 | -def get_include_args(include_dirs, prefix='-I'): | ||
82 | - ''' | ||
83 | - Expand include arguments to refer to the source and build dirs | ||
84 | - by using @SOURCE_ROOT@ and @BUILD_ROOT@ for later substitution | ||
85 | - ''' | ||
86 | - if not include_dirs: | ||
87 | - return [] | ||
88 | - | ||
89 | - dirs_str = [] | ||
90 | - for dirs in unholder(include_dirs): | ||
91 | - if isinstance(dirs, str): | ||
92 | - dirs_str += [f'{prefix}{dirs}'] | ||
93 | - continue | ||
94 | - | ||
95 | - # Should be build.IncludeDirs object. | ||
96 | - basedir = dirs.get_curdir() | ||
97 | - for d in dirs.get_incdirs(): | ||
98 | - expdir = os.path.join(basedir, d) | ||
99 | - srctreedir = os.path.join('@SOURCE_ROOT@', expdir) | ||
100 | - buildtreedir = os.path.join('@BUILD_ROOT@', expdir) | ||
101 | - dirs_str += [f'{prefix}{buildtreedir}', | ||
102 | - f'{prefix}{srctreedir}'] | ||
103 | - for d in dirs.get_extra_build_dirs(): | ||
104 | - dirs_str += [f'{prefix}{d}'] | ||
105 | - | ||
106 | - return dirs_str | ||
107 | - | ||
108 | def is_module_library(fname): | ||
109 | ''' | ||
110 | Check if the file is a library-like file generated by a module-specific | ||
111 | diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py | ||
112 | index d0b053d4f76..c91cda66f8b 100644 | ||
113 | --- a/mesonbuild/modules/gnome.py | ||
114 | +++ b/mesonbuild/modules/gnome.py | ||
115 | @@ -26,7 +26,6 @@ | ||
116 | from .. import mesonlib | ||
117 | from .. import interpreter | ||
118 | from . import GResourceTarget, GResourceHeaderTarget, GirTarget, TypelibTarget, VapiTarget | ||
119 | -from . import get_include_args | ||
120 | from . import ExtensionModule | ||
121 | from . import ModuleReturnValue | ||
122 | from ..mesonlib import ( | ||
123 | @@ -394,7 +393,7 @@ def _get_dependencies_flags(self, deps, state, depends, include_rpath=False, | ||
124 | gi_includes.update([girdir]) | ||
125 | if isinstance(dep, InternalDependency): | ||
126 | cflags.update(dep.get_compile_args()) | ||
127 | - cflags.update(get_include_args(dep.include_directories)) | ||
128 | + cflags.update(state.get_include_args(dep.include_directories)) | ||
129 | for lib in unholder(dep.libraries): | ||
130 | if isinstance(lib, build.SharedLibrary): | ||
131 | internal_ldflags.update(self._get_link_args(state, lib, depends, include_rpath)) | ||
132 | @@ -443,7 +442,7 @@ def _get_dependencies_flags(self, deps, state, depends, include_rpath=False, | ||
133 | else: | ||
134 | external_ldflags.update([lib]) | ||
135 | elif isinstance(dep, (build.StaticLibrary, build.SharedLibrary)): | ||
136 | - cflags.update(get_include_args(dep.get_include_dirs())) | ||
137 | + cflags.update(state.get_include_args(dep.get_include_dirs())) | ||
138 | depends.append(dep) | ||
139 | else: | ||
140 | mlog.log(f'dependency {dep!r} not handled to build gir files') | ||
141 | @@ -853,7 +852,7 @@ def generate_gir(self, state, args, kwargs): | ||
142 | scan_command += self._scan_header(kwargs) | ||
143 | scan_command += self._scan_extra_args(kwargs) | ||
144 | scan_command += ['-I' + srcdir, '-I' + builddir] | ||
145 | - scan_command += get_include_args(girtargets_inc_dirs) | ||
146 | + scan_command += state.get_include_args(girtargets_inc_dirs) | ||
147 | scan_command += ['--filelist=' + self._make_gir_filelist(state, srcdir, ns, nsversion, girtargets, libsources)] | ||
148 | scan_command += self._scan_link_withs(state, depends, kwargs) | ||
149 | scan_command += self._scan_include(state, depends, gir_inc_dirs, kwargs) | ||
150 | @@ -863,8 +862,8 @@ def generate_gir(self, state, args, kwargs): | ||
151 | scan_command += ['--cflags-begin'] | ||
152 | scan_command += cflags | ||
153 | scan_command += ['--cflags-end'] | ||
154 | - scan_command += get_include_args(inc_dirs) | ||
155 | - scan_command += get_include_args(list(gi_includes) + gir_inc_dirs + inc_dirs, prefix='--add-include-path=') | ||
156 | + scan_command += state.get_include_args(inc_dirs) | ||
157 | + scan_command += state.get_include_args(list(gi_includes) + gir_inc_dirs + inc_dirs, prefix='--add-include-path=') | ||
158 | scan_command += list(internal_ldflags) | ||
159 | scan_command += self._scan_gir_targets(state, girtargets) | ||
160 | scan_command += self._scan_langs(state, [lc[0] for lc in langs_compilers]) | ||
161 | @@ -886,7 +885,7 @@ def generate_gir(self, state, args, kwargs): | ||
162 | |||
163 | typelib_output = f'{ns}-{nsversion}.typelib' | ||
164 | typelib_cmd = [gicompiler, scan_target, '--output', '@OUTPUT@'] | ||
165 | - typelib_cmd += get_include_args(gir_inc_dirs, prefix='--includedir=') | ||
166 | + typelib_cmd += state.get_include_args(gir_inc_dirs, prefix='--includedir=') | ||
167 | |||
168 | for incdir in typelib_includes: | ||
169 | typelib_cmd += ["--includedir=" + incdir] | ||
170 | @@ -1127,7 +1126,7 @@ def _get_build_args(self, kwargs, state, depends): | ||
171 | 'Gir include dirs should be include_directories().') | ||
172 | |||
173 | cflags.extend(deps_cflags) | ||
174 | - cflags.extend(get_include_args(inc_dirs)) | ||
175 | + cflags.extend(state.get_include_args(inc_dirs)) | ||
176 | ldflags = [] | ||
177 | ldflags.extend(internal_ldflags) | ||
178 | ldflags.extend(external_ldflags) | ||
179 | diff --git a/mesonbuild/modules/hotdoc.py b/mesonbuild/modules/hotdoc.py | ||
180 | index bf8cd229c0d..89a5d938ea7 100644 | ||
181 | --- a/mesonbuild/modules/hotdoc.py | ||
182 | +++ b/mesonbuild/modules/hotdoc.py | ||
183 | @@ -22,7 +22,6 @@ | ||
184 | from mesonbuild.coredata import MesonException | ||
185 | from . import ModuleReturnValue | ||
186 | from . import ExtensionModule | ||
187 | -from . import get_include_args | ||
188 | from ..dependencies import Dependency, InternalDependency | ||
189 | from ..interpreterbase import FeatureNew, InvalidArguments, noPosargs, noKwargs | ||
190 | from ..interpreter import CustomTargetHolder | ||
191 | @@ -191,7 +190,7 @@ def process_dependencies(self, deps): | ||
192 | for dep in mesonlib.listify(ensure_list(deps)): | ||
193 | dep = getattr(dep, "held_object", dep) | ||
194 | if isinstance(dep, InternalDependency): | ||
195 | - inc_args = get_include_args(dep.include_directories) | ||
196 | + inc_args = self.state.get_include_args(dep.include_directories) | ||
197 | cflags.update([self.replace_dirs_in_string(x) | ||
198 | for x in inc_args]) | ||
199 | cflags.update(self.process_dependencies(dep.libraries)) | ||
200 | diff --git a/mesonbuild/modules/qt.py b/mesonbuild/modules/qt.py | ||
201 | index b7389bd59af..1bf0099d1df 100644 | ||
202 | --- a/mesonbuild/modules/qt.py | ||
203 | +++ b/mesonbuild/modules/qt.py | ||
204 | @@ -23,7 +23,7 @@ | ||
205 | from ..mesonlib import MesonException, extract_as_list, File, unholder, version_compare | ||
206 | from ..dependencies import Dependency | ||
207 | import xml.etree.ElementTree as ET | ||
208 | -from . import ModuleReturnValue, get_include_args, ExtensionModule | ||
209 | +from . import ModuleReturnValue, ExtensionModule | ||
210 | from ..interpreterbase import noPosargs, permittedKwargs, FeatureNew, FeatureNewKwargs | ||
211 | from ..interpreter import extract_required_kwarg | ||
212 | from ..programs import NonExistingExternalProgram | ||
213 | @@ -239,7 +239,7 @@ def preprocess(self, state, args, kwargs): | ||
214 | ui_gen = build.Generator([self.uic], ui_kwargs) | ||
215 | ui_output = ui_gen.process_files(f'Qt{self.qt_version} ui', ui_files, state) | ||
216 | sources.append(ui_output) | ||
217 | - inc = get_include_args(include_dirs=include_directories) | ||
218 | + inc = state.get_include_args(include_dirs=include_directories) | ||
219 | compile_args = [] | ||
220 | for dep in unholder(dependencies): | ||
221 | if isinstance(dep, Dependency): | ||
222 | diff --git a/mesonbuild/modules/windows.py b/mesonbuild/modules/windows.py | ||
223 | index d7a86380885..c4fdc196681 100644 | ||
224 | --- a/mesonbuild/modules/windows.py | ||
225 | +++ b/mesonbuild/modules/windows.py | ||
226 | @@ -19,7 +19,6 @@ | ||
227 | from .. import mlog | ||
228 | from .. import mesonlib, build | ||
229 | from ..mesonlib import MachineChoice, MesonException, extract_as_list, unholder | ||
230 | -from . import get_include_args | ||
231 | from . import ModuleReturnValue | ||
232 | from . import ExtensionModule | ||
233 | from ..interpreter import CustomTargetHolder | ||
234 | @@ -83,12 +82,12 @@ def compile_resources(self, state, args, kwargs): | ||
235 | wrc_depends = extract_as_list(kwargs, 'depends', pop = True) | ||
236 | for d in wrc_depends: | ||
237 | if isinstance(d, CustomTargetHolder): | ||
238 | - extra_args += get_include_args([d.outdir_include()]) | ||
239 | + extra_args += state.get_include_args([d.outdir_include()]) | ||
240 | inc_dirs = extract_as_list(kwargs, 'include_directories', pop = True) | ||
241 | for incd in inc_dirs: | ||
242 | if not isinstance(incd.held_object, (str, build.IncludeDirs)): | ||
243 | raise MesonException('Resource include dirs should be include_directories().') | ||
244 | - extra_args += get_include_args(inc_dirs) | ||
245 | + extra_args += state.get_include_args(inc_dirs) | ||
246 | |||
247 | rescomp, rescomp_type = self._find_resource_compiler(state) | ||
248 | if rescomp_type == ResourceCompilerType.rc: | ||
249 | diff --git a/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-docs.sgml b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-docs.sgml | ||
250 | index 95f73efdf45..6ccd087dc18 100644 | ||
251 | --- a/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-docs.sgml | ||
252 | +++ b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-docs.sgml | ||
253 | @@ -35,7 +35,7 @@ | ||
254 | </partintro> | ||
255 | <xi:include href="xml/foo.xml"/> | ||
256 | <xi:include href="../../include/bar.xml"/> | ||
257 | - <xi:include href="xml/foo-version.xml"/> | ||
258 | + <xi:include href="xml/version.xml"/> | ||
259 | </reference> | ||
260 | |||
261 | </book> | ||
262 | diff --git a/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-sections.txt b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-sections.txt | ||
263 | new file mode 100644 | ||
264 | index 00000000000..d14c8dab010 | ||
265 | --- /dev/null | ||
266 | +++ b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar-sections.txt | ||
267 | @@ -0,0 +1,16 @@ | ||
268 | +<SECTION> | ||
269 | +<FILE>foo</FILE> | ||
270 | +<TITLE>FooObj</TITLE> | ||
271 | +FooObj | ||
272 | +FooObjClass | ||
273 | +foo_do_something | ||
274 | +</SECTION> | ||
275 | + | ||
276 | +<SECTION> | ||
277 | +<FILE>version</FILE> | ||
278 | +<TITLE>version</TITLE> | ||
279 | +FOO_MAJOR_VERSION | ||
280 | +FOO_MINOR_VERSION | ||
281 | +FOO_MICRO_VERSION | ||
282 | +</SECTION> | ||
283 | + | ||
284 | diff --git a/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar.types b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar.types | ||
285 | new file mode 100644 | ||
286 | index 00000000000..0a9c046f3ed | ||
287 | --- /dev/null | ||
288 | +++ b/test cases/frameworks/10 gtk-doc/doc/foobar1/foobar.types | ||
289 | @@ -0,0 +1,4 @@ | ||
290 | +% This include is useless it's a regression test for https://github.com/mesonbuild/meson/issues/8744 | ||
291 | +#include <foo.h> | ||
292 | + | ||
293 | +foo_obj_get_type | ||
294 | diff --git a/test cases/frameworks/10 gtk-doc/doc/foobar1/meson.build b/test cases/frameworks/10 gtk-doc/doc/foobar1/meson.build | ||
295 | index 149c6e956aa..f4b3724dbae 100644 | ||
296 | --- a/test cases/frameworks/10 gtk-doc/doc/foobar1/meson.build | ||
297 | +++ b/test cases/frameworks/10 gtk-doc/doc/foobar1/meson.build | ||
298 | @@ -1,5 +1,9 @@ | ||
299 | gnome.gtkdoc('foobar', | ||
300 | - src_dir : inc, | ||
301 | + src_dir : [inc, '.'], | ||
302 | main_sgml : 'foobar-docs.sgml', | ||
303 | content_files : [docbook, version_xml], | ||
304 | + dependencies: foo_dep, | ||
305 | + # Manually written types file for regression test: | ||
306 | + # https://github.com/mesonbuild/meson/issues/8744 | ||
307 | + gobject_typesfile: 'foobar.types', | ||
308 | install : true) | ||
309 | diff --git a/test cases/frameworks/10 gtk-doc/foo.c b/test cases/frameworks/10 gtk-doc/foo.c | ||
310 | new file mode 100644 | ||
311 | index 00000000000..36c0639ec08 | ||
312 | --- /dev/null | ||
313 | +++ b/test cases/frameworks/10 gtk-doc/foo.c | ||
314 | @@ -0,0 +1,30 @@ | ||
315 | +#include <foo.h> | ||
316 | + | ||
317 | + | ||
318 | +struct _FooObj { | ||
319 | + GObject parent; | ||
320 | + int dummy; | ||
321 | +}; | ||
322 | + | ||
323 | +G_DEFINE_TYPE(FooObj, foo_obj, G_TYPE_OBJECT) | ||
324 | + | ||
325 | +static void foo_obj_init (FooObj *self) | ||
326 | +{ | ||
327 | +} | ||
328 | + | ||
329 | +static void foo_obj_class_init (FooObjClass *klass) | ||
330 | +{ | ||
331 | +} | ||
332 | + | ||
333 | +/** | ||
334 | + * foo_do_something: | ||
335 | + * @self: self | ||
336 | + * | ||
337 | + * Useless function. | ||
338 | + * | ||
339 | + * Returns: 0. | ||
340 | + */ | ||
341 | +int foo_do_something(FooObj *self) | ||
342 | +{ | ||
343 | + return 0; | ||
344 | +} | ||
345 | diff --git a/test cases/frameworks/10 gtk-doc/include/foo.h b/test cases/frameworks/10 gtk-doc/include/foo.h | ||
346 | index 7b8946b6a86..510f3d1ecb5 100644 | ||
347 | --- a/test cases/frameworks/10 gtk-doc/include/foo.h | ||
348 | +++ b/test cases/frameworks/10 gtk-doc/include/foo.h | ||
349 | @@ -1,5 +1,7 @@ | ||
350 | #pragma once | ||
351 | |||
352 | +#include <glib-object.h> | ||
353 | + | ||
354 | /** | ||
355 | * FooIndecision: | ||
356 | * @FOO_MAYBE: Something maybe | ||
357 | @@ -13,3 +15,19 @@ typedef enum { | ||
358 | FOO_POSSIBLY, | ||
359 | } FooIndecision; | ||
360 | |||
361 | +/** | ||
362 | + * FooObjClass: | ||
363 | + * | ||
364 | + * The class | ||
365 | + */ | ||
366 | + | ||
367 | +/** | ||
368 | + * FooObj: | ||
369 | + * | ||
370 | + * The instance | ||
371 | + */ | ||
372 | + | ||
373 | +#define FOO_TYPE_OBJ foo_obj_get_type() | ||
374 | +G_DECLARE_FINAL_TYPE(FooObj, foo_obj, FOO, OBJ, GObject) | ||
375 | + | ||
376 | +int foo_do_something(FooObj *self); | ||
377 | diff --git a/test cases/frameworks/10 gtk-doc/meson.build b/test cases/frameworks/10 gtk-doc/meson.build | ||
378 | index 5c22ad0afa4..292980fafa7 100644 | ||
379 | --- a/test cases/frameworks/10 gtk-doc/meson.build | ||
380 | +++ b/test cases/frameworks/10 gtk-doc/meson.build | ||
381 | @@ -24,4 +24,16 @@ if gtkdoc_ver.version_compare('<1.26') | ||
382 | error('MESON_SKIP_TEST gtk-doc test requires gtkdoc >= 1.26.') | ||
383 | endif | ||
384 | |||
385 | +gobject = dependency('gobject-2.0') | ||
386 | + | ||
387 | +libfoo = library('foo', 'foo.c', | ||
388 | + include_directories: inc, | ||
389 | + dependencies: gobject, | ||
390 | +) | ||
391 | + | ||
392 | +foo_dep = declare_dependency( | ||
393 | + link_with: libfoo, | ||
394 | + include_directories: inc, | ||
395 | +) | ||
396 | + | ||
397 | subdir('doc') | ||
398 | diff --git a/test cases/frameworks/10 gtk-doc/test.json b/test cases/frameworks/10 gtk-doc/test.json | ||
399 | index c44126cc741..03ad0595817 100644 | ||
400 | --- a/test cases/frameworks/10 gtk-doc/test.json | ||
401 | +++ b/test cases/frameworks/10 gtk-doc/test.json | ||
402 | @@ -4,8 +4,8 @@ | ||
403 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/BAR.html"}, | ||
404 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/foobar.devhelp2"}, | ||
405 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/foobar.html"}, | ||
406 | - {"type": "file", "file": "usr/share/gtk-doc/html/foobar/foobar-foo.html"}, | ||
407 | - {"type": "file", "file": "usr/share/gtk-doc/html/foobar/foobar-foo-version.html"}, | ||
408 | + {"type": "file", "file": "usr/share/gtk-doc/html/foobar/FooObj.html"}, | ||
409 | + {"type": "file", "file": "usr/share/gtk-doc/html/foobar/foo-version.html"}, | ||
410 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/home.png"}, | ||
411 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/index.html"}, | ||
412 | {"type": "file", "file": "usr/share/gtk-doc/html/foobar/left.png"}, | ||
diff --git a/meta/recipes-devtools/meson/meson/cross-prop-default.patch b/meta/recipes-devtools/meson/meson/cross-prop-default.patch deleted file mode 100644 index 772395e879..0000000000 --- a/meta/recipes-devtools/meson/meson/cross-prop-default.patch +++ /dev/null | |||
@@ -1,23 +0,0 @@ | |||
1 | meson.build files that use cc.run() in native builds can silently fallback to | ||
2 | meson.get_cross_property() in cross builds without an exe-wrapper, but there's | ||
3 | no way to know that this is happening. | ||
4 | |||
5 | As the defaults may be pessimistic (for example, disabling the support for a | ||
6 | feature that should be enabled) emit a warning when the default is used, so that | ||
7 | the recipe can explicitly set the cross property as relevant. | ||
8 | |||
9 | Upstream-Status: Submitted [https://github.com/mesonbuild/meson/pull/5071] | ||
10 | Signed-off-by: Ross Burton <ross.burton@intel.com> | ||
11 | |||
12 | diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py | ||
13 | index 3c3cfae0..10e741ae 100644 | ||
14 | --- a/mesonbuild/interpreter.py | ||
15 | +++ b/mesonbuild/interpreter.py | ||
16 | @@ -1890,6 +1890,7 @@ class MesonMain(InterpreterObject): | ||
17 | return props[propname] | ||
18 | except Exception: | ||
19 | if len(args) == 2: | ||
20 | + mlog.warning('Cross property %s is using default value %s' % (propname, args[1])) | ||
21 | return args[1] | ||
22 | raise InterpreterException('Unknown cross property: %s.' % propname) | ||
23 | |||
diff --git a/meta/recipes-devtools/meson/meson_0.57.2.bb b/meta/recipes-devtools/meson/meson_0.58.0.bb index de9b905c12..de9b905c12 100644 --- a/meta/recipes-devtools/meson/meson_0.57.2.bb +++ b/meta/recipes-devtools/meson/meson_0.58.0.bb | |||
diff --git a/meta/recipes-devtools/meson/nativesdk-meson_0.57.2.bb b/meta/recipes-devtools/meson/nativesdk-meson_0.58.0.bb index 8778cab124..8778cab124 100644 --- a/meta/recipes-devtools/meson/nativesdk-meson_0.57.2.bb +++ b/meta/recipes-devtools/meson/nativesdk-meson_0.58.0.bb | |||