Patchwork [bitbake-devel,oe-core,RFC,2/2] sstate.bbclass: Add an extra check for sstate_mirrors

login
register
mail settings
Submitter Joe MacDonald
Date June 28, 2013, 3:05 p.m.
Message ID <1372431907-10142-3-git-send-email-joe.macdonald@windriver.com>
Download mbox | patch
Permalink /patch/52569/
State New
Headers show

Comments

Joe MacDonald - June 28, 2013, 3:05 p.m.
BB_NO_NETWORK disables any fetching, however if we're using an external
sstate cache, we may want to be able to fetch those objects even if we are
not fetching the upstream sources.

Signed-off-by: Joe MacDonald <joe.macdonald@windriver.com>
---
 meta/classes/sstate.bbclass |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 28dc312..759fb93 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -515,7 +515,7 @@  def pstaging_fetch(sstatefetch, sstatepkg, d):
                    'file://{0}.siginfo'.format(sstatefetch)]:
         localdata.setVar('SRC_URI', srcuri)
         try:
-            fetcher = bb.fetch2.Fetch([srcuri], localdata, cache=False)
+            fetcher = bb.fetch2.Fetch([srcuri], localdata, cache=False, sstate_cache=True)
             fetcher.download()
 
             # Need to optimise this, if using file:// urls, the fetcher just changes the local path
@@ -632,7 +632,7 @@  def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d):
             bb.debug(2, "SState: Attempting to fetch %s" % srcuri)
 
             try:
-                fetcher = bb.fetch2.Fetch(srcuri.split(), localdata)
+                fetcher = bb.fetch2.Fetch(srcuri.split(), localdata, sstate_cache=True)
                 fetcher.checkstatus()
                 bb.debug(2, "SState: Successful fetch test for %s" % srcuri)
                 ret.append(task)