diff options
Diffstat (limited to 'bitbake/lib/bb/fetch/wget.py')
| -rw-r--r-- | bitbake/lib/bb/fetch/wget.py | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/bitbake/lib/bb/fetch/wget.py b/bitbake/lib/bb/fetch/wget.py index fd93c7ec46..ae1c6ad136 100644 --- a/bitbake/lib/bb/fetch/wget.py +++ b/bitbake/lib/bb/fetch/wget.py | |||
| @@ -30,7 +30,6 @@ import bb | |||
| 30 | from bb import data | 30 | from bb import data |
| 31 | from bb.fetch import Fetch | 31 | from bb.fetch import Fetch |
| 32 | from bb.fetch import FetchError | 32 | from bb.fetch import FetchError |
| 33 | from bb.fetch import uri_replace | ||
| 34 | 33 | ||
| 35 | class Wget(Fetch): | 34 | class Wget(Fetch): |
| 36 | """Class to fetch urls via 'wget'""" | 35 | """Class to fetch urls via 'wget'""" |
| @@ -105,24 +104,9 @@ class Wget(Fetch): | |||
| 105 | data.setVar('OVERRIDES', "wget:" + data.getVar('OVERRIDES', localdata), localdata) | 104 | data.setVar('OVERRIDES', "wget:" + data.getVar('OVERRIDES', localdata), localdata) |
| 106 | data.update_data(localdata) | 105 | data.update_data(localdata) |
| 107 | 106 | ||
| 108 | premirrors = [ i.split() for i in (data.getVar('PREMIRRORS', localdata, 1) or "").split('\n') if i ] | ||
| 109 | for (find, replace) in premirrors: | ||
| 110 | newuri = uri_replace(uri, find, replace, d) | ||
| 111 | if newuri != uri: | ||
| 112 | if fetch_uri(newuri, ud, localdata): | ||
| 113 | return True | ||
| 114 | |||
| 115 | if fetch_uri(uri, ud, localdata): | 107 | if fetch_uri(uri, ud, localdata): |
| 116 | return True | 108 | return True |
| 117 | 109 | ||
| 118 | # try mirrors | ||
| 119 | mirrors = [ i.split() for i in (data.getVar('MIRRORS', localdata, 1) or "").split('\n') if i ] | ||
| 120 | for (find, replace) in mirrors: | ||
| 121 | newuri = uri_replace(uri, find, replace, d) | ||
| 122 | if newuri != uri: | ||
| 123 | if fetch_uri(newuri, ud, localdata): | ||
| 124 | return True | ||
| 125 | |||
| 126 | raise FetchError(uri) | 110 | raise FetchError(uri) |
| 127 | 111 | ||
| 128 | 112 | ||
