diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-08-10 19:39:31 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-08-11 17:19:51 +0100 |
commit | a752b23767189f2678367e47ca0b41f49c56a631 (patch) | |
tree | db25f52f3f0405e79f31b74ad9dfe8c879d8ea6c /meta | |
parent | 970af6b09e1d69041b0d82fa56ace19543405eb1 (diff) | |
download | openembedded-core-a752b23767189f2678367e47ca0b41f49c56a631.tar.gz openembedded-core-a752b23767189f2678367e47ca0b41f49c56a631.tar.bz2 openembedded-core-a752b23767189f2678367e47ca0b41f49c56a631.tar.xz openembedded-core-a752b23767189f2678367e47ca0b41f49c56a631.zip |
sstate: Add level 2 debug so its possible to see what sstate is doing
Currently its hard to figure out if/when sstate is checking for possible
packages to speed up builds. This patch adds level 2 debug output which
better indicates what files are being searched for an why.
[YOCTO #1259]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/sstate.bbclass | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass index c057cc744..d7631cac5 100644 --- a/meta/classes/sstate.bbclass +++ b/meta/classes/sstate.bbclass @@ -477,10 +477,12 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d): for task in range(len(sq_fn)): sstatefile = bb.data.expand("${SSTATE_DIR}/" + sq_hashfn[task] + "_" + mapping[sq_task[task]] + ".tgz", d) sstatefile = sstatefile.replace("${BB_TASKHASH}", sq_hash[task]) - #print("Checking for %s" % sstatefile) if os.path.exists(sstatefile): + bb.debug(2, "SState: Found valid sstate file %s" % sstatefile) ret.append(task) continue + else: + bb.debug(2, "SState: Looked for but didn't find file %s" % sstatefile) mirrors = bb.data.getVar("SSTATE_MIRRORS", d, True) if mirrors: @@ -492,6 +494,8 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d): bb.data.setVar('DL_DIR', dldir, localdata) bb.data.setVar('PREMIRRORS', mirrors, localdata) + bb.debug(2, "SState using premirror of: %s" % mirrors) + for task in range(len(sq_fn)): if task in ret: continue @@ -501,13 +505,15 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d): srcuri = "file://" + os.path.basename(sstatefile) bb.data.setVar('SRC_URI', srcuri, localdata) - #bb.note(str(srcuri)) + bb.debug(2, "SState: Attempting to fetch %s" % srcuri) try: fetcher = bb.fetch2.Fetch(srcuri.split(), localdata) fetcher.checkstatus() + bb.debug(2, "SState: Successful fetch test for %s" % srcuri) ret.append(task) except: + bb.debug(2, "SState: Unsuccessful fetch test for %s" % srcuri) pass return ret |