diff options
| author | Josua Mayer <josua.mayer97@gmail.com> | 2014-02-14 16:02:24 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-02-17 15:28:59 +0000 |
| commit | a204c1e1be8b3ef9f565b0e07e6123e739d02fd0 (patch) | |
| tree | 7ae10c933204e20600c250137fdc9d119469e415 | |
| parent | 8a0a958e25be712add2b133c96a0822b0c2fca4d (diff) | |
| download | poky-a204c1e1be8b3ef9f565b0e07e6123e739d02fd0.tar.gz | |
package.bbclass: do_split_packages should always return something.
So far, when do_split_packages is passed a non-existing folder, it will return nothing.
While building Mesa with PACKAGECONFIG="egl gles" for qemux86, do_package threw a nice exception on a line reading "pkgs += do_split_packages":
"Exception: TypeError: 'NoneType' object is not iterable"
I think a function should always return something, and in this specific case, returning an empty list should be right.
This patch simply fixes the return statement to do just that.
(From OE-Core rev: 39737e00e85bd4a6053f63f0c959fd424aa009be)
Signed-off-by: Josua Mayer <josua.mayer97@gmail.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/classes/package.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass index 042d74c17b..297d962266 100644 --- a/meta/classes/package.bbclass +++ b/meta/classes/package.bbclass | |||
| @@ -126,7 +126,7 @@ def do_split_packages(d, root, file_regex, output_pattern, description, postinst | |||
| 126 | # If the root directory doesn't exist, don't error out later but silently do | 126 | # If the root directory doesn't exist, don't error out later but silently do |
| 127 | # no splitting. | 127 | # no splitting. |
| 128 | if not os.path.exists(dvar + root): | 128 | if not os.path.exists(dvar + root): |
| 129 | return | 129 | return [] |
| 130 | 130 | ||
| 131 | ml = d.getVar("MLPREFIX", True) | 131 | ml = d.getVar("MLPREFIX", True) |
| 132 | if ml: | 132 | if ml: |
