mirror of
https://git.yoctoproject.org/poky
synced 2026-04-04 14:02:22 +02:00
sstate.bbclass: Use bb.utils.to_boolean() for BB_NO_NETWORK
Make it consistent with bitbake (From OE-Core rev: 7fb540c3199bc2b82d60fff678b5e588ab4d1ad6) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
974d786d08
commit
bd2b7d2213
@@ -689,7 +689,8 @@ def pstaging_fetch(sstatefetch, d):
|
||||
|
||||
# if BB_NO_NETWORK is set but we also have SSTATE_MIRROR_ALLOW_NETWORK,
|
||||
# we'll want to allow network access for the current set of fetches.
|
||||
if localdata.getVar('BB_NO_NETWORK') == "1" and localdata.getVar('SSTATE_MIRROR_ALLOW_NETWORK') == "1":
|
||||
if bb.utils.to_boolean(localdata.getVar('BB_NO_NETWORK')) and \
|
||||
bb.utils.to_boolean(localdata.getVar('SSTATE_MIRROR_ALLOW_NETWORK')):
|
||||
localdata.delVar('BB_NO_NETWORK')
|
||||
|
||||
# Try a fetch from the sstate mirror, if it fails just return and
|
||||
@@ -867,7 +868,8 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d, siginfo=False, *,
|
||||
|
||||
# if BB_NO_NETWORK is set but we also have SSTATE_MIRROR_ALLOW_NETWORK,
|
||||
# we'll want to allow network access for the current set of fetches.
|
||||
if localdata.getVar('BB_NO_NETWORK') == "1" and localdata.getVar('SSTATE_MIRROR_ALLOW_NETWORK') == "1":
|
||||
if bb.utils.to_boolean(localdata.getVar('BB_NO_NETWORK')) and \
|
||||
bb.utils.to_boolean(localdata.getVar('SSTATE_MIRROR_ALLOW_NETWORK')):
|
||||
localdata.delVar('BB_NO_NETWORK')
|
||||
|
||||
from bb.fetch2 import FetchConnectionCache
|
||||
|
||||
Reference in New Issue
Block a user