diff options
| author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2017-06-14 16:11:39 +0200 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-07-18 22:39:33 +0100 |
| commit | 819c98d9ea3d9a1dc86f92cf6ea1aa41ba2349ea (patch) | |
| tree | 7c4e406f5fcb8750efa8b24d35a6f4452b424c7b | |
| parent | f93c9157e510bbc2d4d9d5fa74b8b53babc81333 (diff) | |
| download | poky-819c98d9ea3d9a1dc86f92cf6ea1aa41ba2349ea.tar.gz | |
bitbake: cache.py: fix whitespace
(Bitbake rev: e22b1f1c0e57c6ada4fb044791159546e2260dad)
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | bitbake/lib/bb/cache.py | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/bitbake/lib/bb/cache.py b/bitbake/lib/bb/cache.py index 514399269a..86ce0e7861 100644 --- a/bitbake/lib/bb/cache.py +++ b/bitbake/lib/bb/cache.py | |||
| @@ -86,9 +86,9 @@ class RecipeInfoCommon(object): | |||
| 86 | class CoreRecipeInfo(RecipeInfoCommon): | 86 | class CoreRecipeInfo(RecipeInfoCommon): |
| 87 | __slots__ = () | 87 | __slots__ = () |
| 88 | 88 | ||
| 89 | cachefile = "bb_cache.dat" | 89 | cachefile = "bb_cache.dat" |
| 90 | 90 | ||
| 91 | def __init__(self, filename, metadata): | 91 | def __init__(self, filename, metadata): |
| 92 | self.file_depends = metadata.getVar('__depends', False) | 92 | self.file_depends = metadata.getVar('__depends', False) |
| 93 | self.timestamp = bb.parse.cached_mtime(filename) | 93 | self.timestamp = bb.parse.cached_mtime(filename) |
| 94 | self.variants = self.listvar('__VARIANTS', metadata) + [''] | 94 | self.variants = self.listvar('__VARIANTS', metadata) + [''] |
| @@ -122,7 +122,7 @@ class CoreRecipeInfo(RecipeInfoCommon): | |||
| 122 | self.defaultpref = self.intvar('DEFAULT_PREFERENCE', metadata) | 122 | self.defaultpref = self.intvar('DEFAULT_PREFERENCE', metadata) |
| 123 | self.not_world = self.getvar('EXCLUDE_FROM_WORLD', metadata) | 123 | self.not_world = self.getvar('EXCLUDE_FROM_WORLD', metadata) |
| 124 | self.stamp = self.getvar('STAMP', metadata) | 124 | self.stamp = self.getvar('STAMP', metadata) |
| 125 | self.stampclean = self.getvar('STAMPCLEAN', metadata) | 125 | self.stampclean = self.getvar('STAMPCLEAN', metadata) |
| 126 | self.stamp_extrainfo = self.flaglist('stamp-extra-info', self.tasks, metadata) | 126 | self.stamp_extrainfo = self.flaglist('stamp-extra-info', self.tasks, metadata) |
| 127 | self.file_checksums = self.flaglist('file-checksums', self.tasks, metadata, True) | 127 | self.file_checksums = self.flaglist('file-checksums', self.tasks, metadata, True) |
| 128 | self.packages_dynamic = self.listvar('PACKAGES_DYNAMIC', metadata) | 128 | self.packages_dynamic = self.listvar('PACKAGES_DYNAMIC', metadata) |
| @@ -375,8 +375,8 @@ class Cache(NoCache): | |||
| 375 | data = databuilder.data | 375 | data = databuilder.data |
| 376 | 376 | ||
| 377 | # Pass caches_array information into Cache Constructor | 377 | # Pass caches_array information into Cache Constructor |
| 378 | # It will be used later for deciding whether we | 378 | # It will be used later for deciding whether we |
| 379 | # need extra cache file dump/load support | 379 | # need extra cache file dump/load support |
| 380 | self.caches_array = caches_array | 380 | self.caches_array = caches_array |
| 381 | self.cachedir = data.getVar("CACHE") | 381 | self.cachedir = data.getVar("CACHE") |
| 382 | self.clean = set() | 382 | self.clean = set() |
| @@ -421,7 +421,7 @@ class Cache(NoCache): | |||
| 421 | cachesize += os.fstat(cachefile.fileno()).st_size | 421 | cachesize += os.fstat(cachefile.fileno()).st_size |
| 422 | 422 | ||
| 423 | bb.event.fire(bb.event.CacheLoadStarted(cachesize), self.data) | 423 | bb.event.fire(bb.event.CacheLoadStarted(cachesize), self.data) |
| 424 | 424 | ||
| 425 | for cache_class in self.caches_array: | 425 | for cache_class in self.caches_array: |
| 426 | cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash) | 426 | cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash) |
| 427 | with open(cachefile, "rb") as cachefile: | 427 | with open(cachefile, "rb") as cachefile: |
| @@ -438,8 +438,8 @@ class Cache(NoCache): | |||
| 438 | logger.info('Cache version mismatch, rebuilding...') | 438 | logger.info('Cache version mismatch, rebuilding...') |
| 439 | return | 439 | return |
| 440 | elif bitbake_ver != bb.__version__: | 440 | elif bitbake_ver != bb.__version__: |
| 441 | logger.info('Bitbake version mismatch, rebuilding...') | 441 | logger.info('Bitbake version mismatch, rebuilding...') |
| 442 | return | 442 | return |
| 443 | 443 | ||
| 444 | # Load the rest of the cache file | 444 | # Load the rest of the cache file |
| 445 | current_progress = 0 | 445 | current_progress = 0 |
| @@ -616,13 +616,13 @@ class Cache(NoCache): | |||
| 616 | a = fl.find(":True") | 616 | a = fl.find(":True") |
| 617 | b = fl.find(":False") | 617 | b = fl.find(":False") |
| 618 | if ((a < 0) and b) or ((b > 0) and (b < a)): | 618 | if ((a < 0) and b) or ((b > 0) and (b < a)): |
| 619 | f = fl[:b+6] | 619 | f = fl[:b+6] |
| 620 | fl = fl[b+7:] | 620 | fl = fl[b+7:] |
| 621 | elif ((b < 0) and a) or ((a > 0) and (a < b)): | 621 | elif ((b < 0) and a) or ((a > 0) and (a < b)): |
| 622 | f = fl[:a+5] | 622 | f = fl[:a+5] |
| 623 | fl = fl[a+6:] | 623 | fl = fl[a+6:] |
| 624 | else: | 624 | else: |
| 625 | break | 625 | break |
| 626 | fl = fl.strip() | 626 | fl = fl.strip() |
| 627 | if "*" in f: | 627 | if "*" in f: |
| 628 | continue | 628 | continue |
| @@ -886,4 +886,3 @@ class MultiProcessCache(object): | |||
| 886 | p.dump([data, self.__class__.CACHE_VERSION]) | 886 | p.dump([data, self.__class__.CACHE_VERSION]) |
| 887 | 887 | ||
| 888 | bb.utils.unlockfile(glf) | 888 | bb.utils.unlockfile(glf) |
| 889 | |||
