diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-06-07 17:19:41 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-07-27 16:18:50 +0100 |
commit | 9b227ae99123badf137b2b478372aaec16ff4c6f (patch) | |
tree | 5dd4c5c2075319ef876baca886b2d58f684cf48e /meta/lib/oe/utils.py | |
parent | c18aa8d065c389d2f2038da07704b004a3ece9d4 (diff) | |
download | poky-9b227ae99123badf137b2b478372aaec16ff4c6f.tar.gz |
lib/oe/util.py: Add MLPREFIX support to prune_suffix()
prune_suffix() also needs be aware of MLPREFIX when changing PN for
use in BPN.
(From OE-Core rev: 20dd241052afa5ff80b91ebf09b0b48765bc3412)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oe/utils.py')
-rw-r--r-- | meta/lib/oe/utils.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/meta/lib/oe/utils.py b/meta/lib/oe/utils.py index 5a63ed3c3b..b3473d3476 100644 --- a/meta/lib/oe/utils.py +++ b/meta/lib/oe/utils.py | |||
@@ -58,7 +58,12 @@ def prune_suffix(var, suffixes, d): | |||
58 | # remove it if found | 58 | # remove it if found |
59 | for suffix in suffixes: | 59 | for suffix in suffixes: |
60 | if var.endswith(suffix): | 60 | if var.endswith(suffix): |
61 | return var.replace(suffix, "") | 61 | var = var.replace(suffix, "") |
62 | |||
63 | prefix = d.getVar("MLPREFIX", True) | ||
64 | if prefix and var.startswith(prefix): | ||
65 | var = var.replace(prefix, "") | ||
66 | |||
62 | return var | 67 | return var |
63 | 68 | ||
64 | def str_filter(f, str, d): | 69 | def str_filter(f, str, d): |