summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core')
-rw-r--r--meta/recipes-core/glib-2.0/glib-2.0_2.66.7.bb8
1 files changed, 6 insertions, 2 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.66.7.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.66.7.bb
index 15e9dbaf6f..882a89da7a 100644
--- a/meta/recipes-core/glib-2.0/glib-2.0_2.66.7.bb
+++ b/meta/recipes-core/glib-2.0/glib-2.0_2.66.7.bb
@@ -31,7 +31,7 @@ def find_meson_cross_files(d):
31 if bb.data.inherits_class('native', d): 31 if bb.data.inherits_class('native', d):
32 return "" 32 return ""
33 33
34 corebase = d.getVar("COREBASE") 34 thisdir = d.getVar("THISDIR")
35 import collections 35 import collections
36 sitedata = siteinfo_data(d) 36 sitedata = siteinfo_data(d)
37 # filename -> found 37 # filename -> found
@@ -39,7 +39,11 @@ def find_meson_cross_files(d):
39 for path in d.getVar("FILESPATH").split(":"): 39 for path in d.getVar("FILESPATH").split(":"):
40 for element in sitedata: 40 for element in sitedata:
41 filename = os.path.normpath(os.path.join(path, "meson.cross.d", element)) 41 filename = os.path.normpath(os.path.join(path, "meson.cross.d", element))
42 files[filename.replace(corebase, "${COREBASE}")] = os.path.exists(filename) 42 sanitized_path = filename.replace(thisdir, "${THISDIR}")
43 if sanitized_path == filename:
44 bb.error("Cannot add '%s' to --cross-file, because it's not relative to THISDIR '%s' and sstate signature would contain this full path" % (filename, thisdir))
45 continue
46 files[filename.replace(thisdir, "${THISDIR}")] = os.path.exists(filename)
43 47
44 items = ["--cross-file=" + k for k,v in files.items() if v] 48 items = ["--cross-file=" + k for k,v in files.items() if v]
45 d.appendVar("EXTRA_OEMESON", " " + " ".join(items)) 49 d.appendVar("EXTRA_OEMESON", " " + " ".join(items))