diff options
Diffstat (limited to 'meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb')
-rw-r--r-- | meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb index 7bf8648cad..953fba501a 100644 --- a/meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb +++ b/meta/recipes-core/glib-2.0/glib-2.0_2.62.4.bb | |||
@@ -18,7 +18,31 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \ | |||
18 | " | 18 | " |
19 | 19 | ||
20 | SRC_URI_append_class-native = " file://relocate-modules.patch" | 20 | SRC_URI_append_class-native = " file://relocate-modules.patch" |
21 | SRC_URI_append_class-target = " file://glib-meson.cross" | ||
22 | 21 | ||
23 | SRC_URI[md5sum] = "d52234ecba128932bed90bbc3553bfe5" | 22 | SRC_URI[md5sum] = "d52234ecba128932bed90bbc3553bfe5" |
24 | SRC_URI[sha256sum] = "4c84030d77fa9712135dfa8036ad663925655ae95b1d19399b6200e869925bbc" | 23 | SRC_URI[sha256sum] = "4c84030d77fa9712135dfa8036ad663925655ae95b1d19399b6200e869925bbc" |
24 | |||
25 | # Find any meson cross files in FILESPATH that are relevant for the current | ||
26 | # build (using siteinfo) and add them to EXTRA_OEMESON. | ||
27 | inherit siteinfo | ||
28 | def find_meson_cross_files(d): | ||
29 | if bb.data.inherits_class('native', d): | ||
30 | return "" | ||
31 | |||
32 | import collections | ||
33 | sitedata = siteinfo_data(d) | ||
34 | # filename -> found | ||
35 | files = collections.OrderedDict() | ||
36 | for path in d.getVar("FILESPATH").split(":"): | ||
37 | for element in sitedata: | ||
38 | filename = os.path.join(path, "meson.cross.d", element) | ||
39 | files[filename] = os.path.exists(filename) | ||
40 | |||
41 | items = ["--cross-file=" + k for k,v in files.items() if v] | ||
42 | d.appendVar("EXTRA_OEMESON", " " + " ".join(items)) | ||
43 | items = ["%s:%s" % (k, "True" if v else "False") for k,v in files.items()] | ||
44 | d.appendVarFlag("do_configure", "file-checksums", " " + " ".join(items)) | ||
45 | |||
46 | python () { | ||
47 | find_meson_cross_files(d) | ||
48 | } | ||