summaryrefslogtreecommitdiffstats
path: root/meta-gnome
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2023-04-30 22:13:27 -0700
committerKhem Raj <raj.khem@gmail.com>2023-04-30 23:05:52 -0700
commitb16278ea0f69b4e710b8779218c2be945ae73dcf (patch)
treefb4c233c1a5432fab59d1ee04ef82cee7ab0dd76 /meta-gnome
parent6ca9f1c2e5d105096a438389a3431633c3e0cc07 (diff)
downloadmeta-openembedded-b16278ea0f69b4e710b8779218c2be945ae73dcf.tar.gz
geary: Use sysroot prefix with pkg-config in meson
Fixes ../git/meson.build:223:0: ERROR: File /usr/share/xml/iso-codes/iso_639.xml does not exist. Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-gnome')
-rw-r--r--meta-gnome/recipes-connectivity/geary/geary/0001-meson-Use-PKG_CONFIG_SYSROOT_DIR-when-using-pkg-conf.patch51
-rw-r--r--meta-gnome/recipes-connectivity/geary/geary_43.0.bb1
2 files changed, 52 insertions, 0 deletions
diff --git a/meta-gnome/recipes-connectivity/geary/geary/0001-meson-Use-PKG_CONFIG_SYSROOT_DIR-when-using-pkg-conf.patch b/meta-gnome/recipes-connectivity/geary/geary/0001-meson-Use-PKG_CONFIG_SYSROOT_DIR-when-using-pkg-conf.patch
new file mode 100644
index 000000000..1e0640a66
--- /dev/null
+++ b/meta-gnome/recipes-connectivity/geary/geary/0001-meson-Use-PKG_CONFIG_SYSROOT_DIR-when-using-pkg-conf.patch
@@ -0,0 +1,51 @@
1From a300be5877f35379bb569313eec901bda9c8d762 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sun, 30 Apr 2023 22:08:39 -0700
4Subject: [PATCH] meson: Use PKG_CONFIG_SYSROOT_DIR when using pkg-config
5
6OE cross-builds and absolute paths found by pkg-config points to
7non-sysroot'ed locations which are not correct as they point into native
8sysroot from build machine which is incorrect.
9
10Upstream-Status: Inappropriate [OE-specific]
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12---
13 meson.build | 8 +++++---
14 1 file changed, 5 insertions(+), 3 deletions(-)
15
16diff --git a/meson.build b/meson.build
17index d563dd08..9b72aeb4 100644
18--- a/meson.build
19+++ b/meson.build
20@@ -38,6 +38,9 @@ metadata_dir = meson.project_source_root() / 'bindings'/ 'metadata'
21 po_dir = meson.project_source_root() / 'po'
22 vapi_dir = meson.project_source_root() / 'bindings' / 'vapi'
23
24+# pkg-config sysroot location
25+pkgconf_sysroot = run_command('python3', '-c', 'import os; print(os.environ.get("PKG_CONFIG_SYSROOT_DIR"))').stdout().strip()
26+
27 # Compiler configuration
28 add_project_arguments([
29 # Make sure Meson can find custom VAPIs
30@@ -120,7 +123,7 @@ icu_uc = declare_dependency(
31 if libunwind_dep.found()
32 # We need to add native lib to the search path for these so Flatpak
33 # builds can find it.
34- unwind_lib = libunwind_dep.get_variable(pkgconfig: 'libdir')
35+ unwind_lib = pkgconf_sysroot + libunwind_dep.get_variable(pkgconfig: 'libdir')
36 libunwind = declare_dependency(
37 dependencies: [
38 valac.find_library('libunwind', dirs: [vapi_dir, unwind_lib]),
39@@ -207,8 +210,7 @@ vala_unit_proj = subproject(
40 vala_unit_dep = vala_unit_proj.get_variable('vala_unit_dep')
41
42 # Language detection
43-
44-iso_codes_dir = iso_codes.get_variable(pkgconfig: 'prefix')/'share'/'xml'/'iso-codes'
45+iso_codes_dir = pkgconf_sysroot + iso_codes.get_variable(pkgconfig: 'prefix')/'share'/'xml'/'iso-codes'
46
47 iso_639_xml = get_option('iso_639_xml')
48 if iso_639_xml == ''
49--
502.40.1
51
diff --git a/meta-gnome/recipes-connectivity/geary/geary_43.0.bb b/meta-gnome/recipes-connectivity/geary/geary_43.0.bb
index 08899fd4a..ff7a9ee69 100644
--- a/meta-gnome/recipes-connectivity/geary/geary_43.0.bb
+++ b/meta-gnome/recipes-connectivity/geary/geary_43.0.bb
@@ -35,6 +35,7 @@ inherit meson pkgconfig mime-xdg gtk-icon-cache gobject-introspection vala featu
35 35
36SRC_URI = " \ 36SRC_URI = " \
37 git://github.com/GNOME/geary.git;nobranch=1;protocol=https \ 37 git://github.com/GNOME/geary.git;nobranch=1;protocol=https \
38 file://0001-meson-Use-PKG_CONFIG_SYSROOT_DIR-when-using-pkg-conf.patch \
38" 39"
39 40
40S = "${WORKDIR}/git" 41S = "${WORKDIR}/git"