diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-05-27 15:13:54 +0100 |
---|---|---|
committer | Saul Wold <sgw@linux.intel.com> | 2011-05-27 10:48:28 -0700 |
commit | 9425e8eee19a5a74a3aa35eb7e201c3a8e7fe8e6 (patch) | |
tree | 275bd88af2fa25e3df49af6ee890b9621e641e2f /bitbake/lib/bb | |
parent | dd7e260fe374e337a385d1cb8951cb3de8a2c741 (diff) | |
download | poky-9425e8eee19a5a74a3aa35eb7e201c3a8e7fe8e6.tar.gz |
bitbake/cooker.py: Ensure BBFILES is processed in order
The files found by collect_bbfiles should be processed in order but due
to being processed using python's set(), the order was not being preserved.
Use a list instead as whilst the code is slightly more ugly, order
is preserved.
Addresses [YOCTO #1100]
Acked-by: Darren Hart <dvhart@linux.intel.com>
(Bitbake rev: c12dd868368bdc3a4f800e075a30c67edca28d47)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/cooker.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index a1cd4d750e..707384aa68 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py | |||
@@ -941,16 +941,21 @@ class BBCooker: | |||
941 | collectlog.error("no recipe files to build, check your BBPATH and BBFILES?") | 941 | collectlog.error("no recipe files to build, check your BBPATH and BBFILES?") |
942 | bb.event.fire(CookerExit(), self.configuration.event_data) | 942 | bb.event.fire(CookerExit(), self.configuration.event_data) |
943 | 943 | ||
944 | newfiles = set() | 944 | # Can't use set here as order is important |
945 | newfiles = [] | ||
945 | for f in files: | 946 | for f in files: |
946 | if os.path.isdir(f): | 947 | if os.path.isdir(f): |
947 | dirfiles = self.find_bbfiles(f) | 948 | dirfiles = self.find_bbfiles(f) |
948 | newfiles.update(dirfiles) | 949 | for g in dirfiles: |
950 | if g not in newfiles: | ||
951 | newfiles.append(g) | ||
949 | else: | 952 | else: |
950 | globbed = glob.glob(f) | 953 | globbed = glob.glob(f) |
951 | if not globbed and os.path.exists(f): | 954 | if not globbed and os.path.exists(f): |
952 | globbed = [f] | 955 | globbed = [f] |
953 | newfiles.update(globbed) | 956 | for g in globbed: |
957 | if g not in newfiles: | ||
958 | newfiles.append(g) | ||
954 | 959 | ||
955 | bbmask = bb.data.getVar('BBMASK', self.configuration.data, 1) | 960 | bbmask = bb.data.getVar('BBMASK', self.configuration.data, 1) |
956 | 961 | ||