diff options
author | Ross Burton <ross.burton@intel.com> | 2015-02-02 15:09:25 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-04-15 15:56:06 +0100 |
commit | fecee8ffdc653a9e909250bce37c42794b101d6b (patch) | |
tree | 3b20b2f90cf9f2a3b902ed13f73d9655c09877a1 /bitbake/lib/bb/data_smart.py | |
parent | 67cabcd94f847274067123f6514bde861664a5bc (diff) | |
download | poky-fecee8ffdc653a9e909250bce37c42794b101d6b.tar.gz |
bitbake: bitbake: data_smart: split expanded removal values when handling _remove
Given these assignments:
TEST="a b c d"
TEST_remove = "b d"
TEST evaluates to "a c". However, if the _remove override is given as a
variable:
TEST="a b c d"
FOO = "b d"
TEST_remove = "${FOO}
TEST evaluates to "a b c d", because when FOO is expanded it isn't split into a
list.
Solve this by splitting all members of removeactive once they've been expanded.
[ YOCTO #7272 ]
(Bitbake rev: 207013b6dde82f9654f9be996695c8335b95a288)
(Bitbake rev: c25b0e0ca289f6ad0ed697a0b0252fa48ab5dd0b)
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/data_smart.py')
-rw-r--r-- | bitbake/lib/bb/data_smart.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py index 9a42a17062..d4bb98dd74 100644 --- a/bitbake/lib/bb/data_smart.py +++ b/bitbake/lib/bb/data_smart.py | |||
@@ -616,7 +616,8 @@ class DataSmart(MutableMapping): | |||
616 | cachename = var + "[" + flag + "]" | 616 | cachename = var + "[" + flag + "]" |
617 | value = self.expand(value, cachename) | 617 | value = self.expand(value, cachename) |
618 | if value and flag == "_content" and local_var is not None and "_removeactive" in local_var: | 618 | if value and flag == "_content" and local_var is not None and "_removeactive" in local_var: |
619 | removes = [self.expand(r) for r in local_var["_removeactive"]] | 619 | removes = [self.expand(r).split() for r in local_var["_removeactive"]] |
620 | removes = reduce(lambda a, b: a+b, removes, []) | ||
620 | filtered = filter(lambda v: v not in removes, | 621 | filtered = filter(lambda v: v not in removes, |
621 | value.split()) | 622 | value.split()) |
622 | value = " ".join(filtered) | 623 | value = " ".join(filtered) |