diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-11 22:55:14 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-13 13:41:32 +0100 |
commit | 6cc681806843a89a5bcaa0e733f8a97d88f1a8c2 (patch) | |
tree | c82274d83100fc22e5bbd218393c559bcbde2d4f /bitbake/lib/bb/runqueue.py | |
parent | fce8da957fd2bbf1c3b02dfe34bc18a0bce37d65 (diff) | |
download | openembedded-core-contrib-6cc681806843a89a5bcaa0e733f8a97d88f1a8c2.tar.gz |
bitbake: runqueue: Improve timestamp comparisons
python3 cares more about invalid type comparisons. Add break statements
and better tests to make the code paths clearer and avoid type issues
in python3. No code functionality change.
(Bitbake rev: 2c39ebdd2762d027f007a6a769fdf023cdf3da2b)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/runqueue.py')
-rw-r--r-- | bitbake/lib/bb/runqueue.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py index 8b3fe5a957..aaaafc594f 100644 --- a/bitbake/lib/bb/runqueue.py +++ b/bitbake/lib/bb/runqueue.py @@ -1085,15 +1085,19 @@ class RunQueue: stampfile3 = bb.build.stampfile(taskname2 + "_setscene", self.rqdata.dataCache, fn2) t2 = get_timestamp(stampfile2) t3 = get_timestamp(stampfile3) + if t3 and not t2: + continue if t3 and t3 > t2: - continue + continue if fn == fn2 or (fulldeptree and fn2 not in stampwhitelist): if not t2: logger.debug(2, 'Stampfile %s does not exist', stampfile2) iscurrent = False + break if t1 < t2: logger.debug(2, 'Stampfile %s < %s', stampfile, stampfile2) iscurrent = False + break if recurse and iscurrent: if dep in cache: iscurrent = cache[dep] |