summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-21 20:46:14 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-22 11:35:23 +0000
commit70f18264cec44914f6f790890281939ddbcea3b1 (patch)
treebf8f37b7bd57fcbc56ac1d237b8335fb0f16af04 /bitbake
parentf4a924897544e634aaa61b6d9863b46bfb799577 (diff)
downloadpoky-70f18264cec44914f6f790890281939ddbcea3b1.tar.gz
bitbake: data/cooker: Sort output data shown by -e
Displaying the environment data in a sorted manner makes it easier to compare data between different setups and means you can know where to find specific entries. (Bitbake rev: baa417e44b009149eb1dfb07d5a488740b6e68ef) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/cooker.py2
-rw-r--r--bitbake/lib/bb/data.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 662a7ac071..e3f5317f7c 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -648,7 +648,7 @@ class BBCooker:
648 648
649 # emit the metadata which isnt valid shell 649 # emit the metadata which isnt valid shell
650 data.expandKeys(envdata) 650 data.expandKeys(envdata)
651 for e in envdata.keys(): 651 for e in sorted(envdata.keys()):
652 if envdata.getVarFlag(e, 'func', False) and envdata.getVarFlag(e, 'python', False): 652 if envdata.getVarFlag(e, 'func', False) and envdata.getVarFlag(e, 'python', False):
653 logger.plain("\npython %s () {\n%s}\n", e, envdata.getVar(e, False)) 653 logger.plain("\npython %s () {\n%s}\n", e, envdata.getVar(e, False))
654 654
diff --git a/bitbake/lib/bb/data.py b/bitbake/lib/bb/data.py
index d145f1b0ab..a85cb3abff 100644
--- a/bitbake/lib/bb/data.py
+++ b/bitbake/lib/bb/data.py
@@ -196,7 +196,7 @@ def emit_env(o=sys.__stdout__, d = init(), all=False):
196 keys = sorted((key for key in d.keys() if not key.startswith("__")), key=isfunc) 196 keys = sorted((key for key in d.keys() if not key.startswith("__")), key=isfunc)
197 grouped = groupby(keys, isfunc) 197 grouped = groupby(keys, isfunc)
198 for isfunc, keys in grouped: 198 for isfunc, keys in grouped:
199 for key in keys: 199 for key in sorted(keys):
200 emit_var(key, o, d, all and not isfunc) and o.write('\n') 200 emit_var(key, o, d, all and not isfunc) and o.write('\n')
201 201
202def exported_keys(d): 202def exported_keys(d):