diff options
-rw-r--r-- | bitbake/lib/bb/utils.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py index 6ba1d2a3766..6a165df6f51 100644 --- a/bitbake/lib/bb/utils.py +++ b/bitbake/lib/bb/utils.py @@ -1537,6 +1537,13 @@ def get_file_layer(filename, d, collection_res={}): return result +def layer_path(layername, d): + bbpath = d.getVar("BBPATH").split(":") + pattern = d.getVar('BBFILE_PATTERN_' + layername) + for path in reversed(sorted(bbpath)): + if re.match(pattern, path + "/"): + return path + return None # Constant taken from http://linux.die.net/include/linux/prctl.h PR_SET_PDEATHSIG = 1 |