[gnome-continuous-yocto/gnomeostree-3.28-rocko: 2470/8267] bitbake: build: Allow dirs/cleandirs to work for empty functions
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-continuous-yocto/gnomeostree-3.28-rocko: 2470/8267] bitbake: build: Allow dirs/cleandirs to work for empty functions
- Date: Sat, 16 Dec 2017 23:16:31 +0000 (UTC)
commit 53b1fa2d3e1244c46a705d9a40ca0dbee92eab98
Author: Richard Purdie <richard purdie linuxfoundation org>
Date: Wed Sep 14 22:29:43 2016 +0100
bitbake: build: Allow dirs/cleandirs to work for empty functions
Users are surprised when dirs/cleandirs aren't acted upon for
empty functions. This reorders the code slightly so that those
flags are acted upon for empty functions as there are cases where
this is expected.
[YOCTO #10256]
(Bitbake rev: 5bf874673d75b5f4ff2b34f0ab8502558ee84d00)
Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>
bitbake/lib/bb/build.py | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/bitbake/lib/bb/build.py b/bitbake/lib/bb/build.py
index 310b5c0..fcf0149 100644
--- a/bitbake/lib/bb/build.py
+++ b/bitbake/lib/bb/build.py
@@ -193,12 +193,6 @@ def exec_func(func, d, dirs = None, pythonexception=False):
except:
oldcwd = None
- body = d.getVar(func, False)
- if not body:
- if body is None:
- logger.warning("Function %s doesn't exist", func)
- return
-
flags = d.getVarFlags(func)
cleandirs = flags.get('cleandirs')
if cleandirs:
@@ -217,6 +211,13 @@ def exec_func(func, d, dirs = None, pythonexception=False):
adir = dirs[-1]
else:
adir = None
+
+ body = d.getVar(func, False)
+ if not body:
+ if body is None:
+ logger.warning("Function %s doesn't exist", func)
+ return
+
ispython = flags.get('python')
lockflag = flags.get('lockfiles')
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]