summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r--bitbake/lib/bb/fetch2/bzr.py7
-rw-r--r--bitbake/lib/bb/fetch2/clearcase.py1
-rw-r--r--bitbake/lib/bb/fetch2/cvs.py2
-rw-r--r--bitbake/lib/bb/fetch2/git.py1
-rw-r--r--bitbake/lib/bb/fetch2/gitannex.py1
-rw-r--r--bitbake/lib/bb/fetch2/gitsm.py1
-rw-r--r--bitbake/lib/bb/fetch2/hg.py1
-rw-r--r--bitbake/lib/bb/fetch2/local.py1
-rw-r--r--bitbake/lib/bb/fetch2/osc.py5
-rw-r--r--bitbake/lib/bb/fetch2/perforce.py3
-rw-r--r--bitbake/lib/bb/fetch2/repo.py1
-rw-r--r--bitbake/lib/bb/fetch2/sftp.py2
-rw-r--r--bitbake/lib/bb/fetch2/ssh.py1
-rw-r--r--bitbake/lib/bb/fetch2/svn.py5
-rw-r--r--bitbake/lib/bb/fetch2/wget.py5
15 files changed, 11 insertions, 26 deletions
diff --git a/bitbake/lib/bb/fetch2/bzr.py b/bitbake/lib/bb/fetch2/bzr.py
index 0f1c420ef7..16123f8af9 100644
--- a/bitbake/lib/bb/fetch2/bzr.py
+++ b/bitbake/lib/bb/fetch2/bzr.py
@@ -27,7 +27,6 @@ import os
27import sys 27import sys
28import logging 28import logging
29import bb 29import bb
30from bb import data
31from bb.fetch2 import FetchMethod 30from bb.fetch2 import FetchMethod
32from bb.fetch2 import FetchError 31from bb.fetch2 import FetchError
33from bb.fetch2 import runfetchcmd 32from bb.fetch2 import runfetchcmd
@@ -43,14 +42,14 @@ class Bzr(FetchMethod):
43 """ 42 """
44 # Create paths to bzr checkouts 43 # Create paths to bzr checkouts
45 relpath = self._strip_leading_slashes(ud.path) 44 relpath = self._strip_leading_slashes(ud.path)
46 ud.pkgdir = os.path.join(data.expand('${BZRDIR}', d), ud.host, relpath) 45 ud.pkgdir = os.path.join(d.expand('${BZRDIR}'), ud.host, relpath)
47 46
48 ud.setup_revisions(d) 47 ud.setup_revisions(d)
49 48
50 if not ud.revision: 49 if not ud.revision:
51 ud.revision = self.latest_revision(ud, d) 50 ud.revision = self.latest_revision(ud, d)
52 51
53 ud.localfile = data.expand('bzr_%s_%s_%s.tar.gz' % (ud.host, ud.path.replace('/', '.'), ud.revision), d) 52 ud.localfile = d.expand('bzr_%s_%s_%s.tar.gz' % (ud.host, ud.path.replace('/', '.'), ud.revision))
54 53
55 def _buildbzrcommand(self, ud, d, command): 54 def _buildbzrcommand(self, ud, d, command):
56 """ 55 """
@@ -58,7 +57,7 @@ class Bzr(FetchMethod):
58 command is "fetch", "update", "revno" 57 command is "fetch", "update", "revno"
59 """ 58 """
60 59
61 basecmd = data.expand('${FETCHCMD_bzr}', d) 60 basecmd = d.expand('${FETCHCMD_bzr}')
62 61
63 proto = ud.parm.get('protocol', 'http') 62 proto = ud.parm.get('protocol', 'http')
64 63
diff --git a/bitbake/lib/bb/fetch2/clearcase.py b/bitbake/lib/bb/fetch2/clearcase.py
index 8df8f53d2f..36beab6a5b 100644
--- a/bitbake/lib/bb/fetch2/clearcase.py
+++ b/bitbake/lib/bb/fetch2/clearcase.py
@@ -65,7 +65,6 @@ import os
65import sys 65import sys
66import shutil 66import shutil
67import bb 67import bb
68from bb import data
69from bb.fetch2 import FetchMethod 68from bb.fetch2 import FetchMethod
70from bb.fetch2 import FetchError 69from bb.fetch2 import FetchError
71from bb.fetch2 import runfetchcmd 70from bb.fetch2 import runfetchcmd
diff --git a/bitbake/lib/bb/fetch2/cvs.py b/bitbake/lib/bb/fetch2/cvs.py
index 64c50c2165..490c954718 100644
--- a/bitbake/lib/bb/fetch2/cvs.py
+++ b/bitbake/lib/bb/fetch2/cvs.py
@@ -63,7 +63,7 @@ class Cvs(FetchMethod):
63 if 'fullpath' in ud.parm: 63 if 'fullpath' in ud.parm:
64 fullpath = '_fullpath' 64 fullpath = '_fullpath'
65 65
66 ud.localfile = bb.data.expand('%s_%s_%s_%s%s%s.tar.gz' % (ud.module.replace('/', '.'), ud.host, ud.tag, ud.date, norecurse, fullpath), d) 66 ud.localfile = d.expand('%s_%s_%s_%s%s%s.tar.gz' % (ud.module.replace('/', '.'), ud.host, ud.tag, ud.date, norecurse, fullpath))
67 67
68 def need_update(self, ud, d): 68 def need_update(self, ud, d):
69 if (ud.date == "now"): 69 if (ud.date == "now"):
diff --git a/bitbake/lib/bb/fetch2/git.py b/bitbake/lib/bb/fetch2/git.py
index 0a5785d486..0779e809a3 100644
--- a/bitbake/lib/bb/fetch2/git.py
+++ b/bitbake/lib/bb/fetch2/git.py
@@ -76,7 +76,6 @@ import re
76import bb 76import bb
77import errno 77import errno
78import bb.progress 78import bb.progress
79from bb import data
80from bb.fetch2 import FetchMethod 79from bb.fetch2 import FetchMethod
81from bb.fetch2 import runfetchcmd 80from bb.fetch2 import runfetchcmd
82from bb.fetch2 import logger 81from bb.fetch2 import logger
diff --git a/bitbake/lib/bb/fetch2/gitannex.py b/bitbake/lib/bb/fetch2/gitannex.py
index 4937a10891..c66c211428 100644
--- a/bitbake/lib/bb/fetch2/gitannex.py
+++ b/bitbake/lib/bb/fetch2/gitannex.py
@@ -22,7 +22,6 @@ BitBake 'Fetch' git annex implementation
22 22
23import os 23import os
24import bb 24import bb
25from bb import data
26from bb.fetch2.git import Git 25from bb.fetch2.git import Git
27from bb.fetch2 import runfetchcmd 26from bb.fetch2 import runfetchcmd
28from bb.fetch2 import logger 27from bb.fetch2 import logger
diff --git a/bitbake/lib/bb/fetch2/gitsm.py b/bitbake/lib/bb/fetch2/gitsm.py
index 939fb3f09f..a95584c821 100644
--- a/bitbake/lib/bb/fetch2/gitsm.py
+++ b/bitbake/lib/bb/fetch2/gitsm.py
@@ -31,7 +31,6 @@ NOTE: Switching a SRC_URI from "git://" to "gitsm://" requires a clean of your r
31 31
32import os 32import os
33import bb 33import bb
34from bb import data
35from bb.fetch2.git import Git 34from bb.fetch2.git import Git
36from bb.fetch2 import runfetchcmd 35from bb.fetch2 import runfetchcmd
37from bb.fetch2 import logger 36from bb.fetch2 import logger
diff --git a/bitbake/lib/bb/fetch2/hg.py b/bitbake/lib/bb/fetch2/hg.py
index ddbebb5f36..b5f268601c 100644
--- a/bitbake/lib/bb/fetch2/hg.py
+++ b/bitbake/lib/bb/fetch2/hg.py
@@ -29,7 +29,6 @@ import sys
29import logging 29import logging
30import bb 30import bb
31import errno 31import errno
32from bb import data
33from bb.fetch2 import FetchMethod 32from bb.fetch2 import FetchMethod
34from bb.fetch2 import FetchError 33from bb.fetch2 import FetchError
35from bb.fetch2 import MissingParameterError 34from bb.fetch2 import MissingParameterError
diff --git a/bitbake/lib/bb/fetch2/local.py b/bitbake/lib/bb/fetch2/local.py
index 83778883e0..2ff77234e5 100644
--- a/bitbake/lib/bb/fetch2/local.py
+++ b/bitbake/lib/bb/fetch2/local.py
@@ -29,7 +29,6 @@ import os
29import urllib.request, urllib.parse, urllib.error 29import urllib.request, urllib.parse, urllib.error
30import bb 30import bb
31import bb.utils 31import bb.utils
32from bb import data
33from bb.fetch2 import FetchMethod, FetchError 32from bb.fetch2 import FetchMethod, FetchError
34from bb.fetch2 import logger 33from bb.fetch2 import logger
35 34
diff --git a/bitbake/lib/bb/fetch2/osc.py b/bitbake/lib/bb/fetch2/osc.py
index 26f88e1f46..2b4f7d9c13 100644
--- a/bitbake/lib/bb/fetch2/osc.py
+++ b/bitbake/lib/bb/fetch2/osc.py
@@ -10,7 +10,6 @@ import os
10import sys 10import sys
11import logging 11import logging
12import bb 12import bb
13from bb import data
14from bb.fetch2 import FetchMethod 13from bb.fetch2 import FetchMethod
15from bb.fetch2 import FetchError 14from bb.fetch2 import FetchError
16from bb.fetch2 import MissingParameterError 15from bb.fetch2 import MissingParameterError
@@ -47,7 +46,7 @@ class Osc(FetchMethod):
47 else: 46 else:
48 ud.revision = "" 47 ud.revision = ""
49 48
50 ud.localfile = data.expand('%s_%s_%s.tar.gz' % (ud.module.replace('/', '.'), ud.path.replace('/', '.'), ud.revision), d) 49 ud.localfile = d.expand('%s_%s_%s.tar.gz' % (ud.module.replace('/', '.'), ud.path.replace('/', '.'), ud.revision))
51 50
52 def _buildosccommand(self, ud, d, command): 51 def _buildosccommand(self, ud, d, command):
53 """ 52 """
@@ -55,7 +54,7 @@ class Osc(FetchMethod):
55 command is "fetch", "update", "info" 54 command is "fetch", "update", "info"
56 """ 55 """
57 56
58 basecmd = data.expand('${FETCHCMD_osc}', d) 57 basecmd = d.expand('${FETCHCMD_osc}')
59 58
60 proto = ud.parm.get('protocol', 'ocs') 59 proto = ud.parm.get('protocol', 'ocs')
61 60
diff --git a/bitbake/lib/bb/fetch2/perforce.py b/bitbake/lib/bb/fetch2/perforce.py
index e00cca90e7..3debad59f4 100644
--- a/bitbake/lib/bb/fetch2/perforce.py
+++ b/bitbake/lib/bb/fetch2/perforce.py
@@ -26,7 +26,6 @@ BitBake 'Fetch' implementation for perforce
26import os 26import os
27import logging 27import logging
28import bb 28import bb
29from bb import data
30from bb.fetch2 import FetchMethod 29from bb.fetch2 import FetchMethod
31from bb.fetch2 import FetchError 30from bb.fetch2 import FetchError
32from bb.fetch2 import logger 31from bb.fetch2 import logger
@@ -89,7 +88,7 @@ class Perforce(FetchMethod):
89 88
90 ud.setup_revisions(d) 89 ud.setup_revisions(d)
91 90
92 ud.localfile = data.expand('%s_%s_%s.tar.gz' % (cleanedhost, cleanedpath, ud.revision), d) 91 ud.localfile = d.expand('%s_%s_%s.tar.gz' % (cleanedhost, cleanedpath, ud.revision))
93 92
94 def _buildp4command(self, ud, d, command, depot_filename=None): 93 def _buildp4command(self, ud, d, command, depot_filename=None):
95 """ 94 """
diff --git a/bitbake/lib/bb/fetch2/repo.py b/bitbake/lib/bb/fetch2/repo.py
index 24dcebb0cb..1be91cc698 100644
--- a/bitbake/lib/bb/fetch2/repo.py
+++ b/bitbake/lib/bb/fetch2/repo.py
@@ -25,7 +25,6 @@ BitBake "Fetch" repo (git) implementation
25 25
26import os 26import os
27import bb 27import bb
28from bb import data
29from bb.fetch2 import FetchMethod 28from bb.fetch2 import FetchMethod
30from bb.fetch2 import runfetchcmd 29from bb.fetch2 import runfetchcmd
31 30
diff --git a/bitbake/lib/bb/fetch2/sftp.py b/bitbake/lib/bb/fetch2/sftp.py
index da857dd9ff..81884a6aa4 100644
--- a/bitbake/lib/bb/fetch2/sftp.py
+++ b/bitbake/lib/bb/fetch2/sftp.py
@@ -62,12 +62,10 @@ SRC_URI = "sftp://user@host.example.com/dir/path.file.txt"
62import os 62import os
63import bb 63import bb
64import urllib.request, urllib.parse, urllib.error 64import urllib.request, urllib.parse, urllib.error
65from bb import data
66from bb.fetch2 import URI 65from bb.fetch2 import URI
67from bb.fetch2 import FetchMethod 66from bb.fetch2 import FetchMethod
68from bb.fetch2 import runfetchcmd 67from bb.fetch2 import runfetchcmd
69 68
70
71class SFTP(FetchMethod): 69class SFTP(FetchMethod):
72 """Class to fetch urls via 'sftp'""" 70 """Class to fetch urls via 'sftp'"""
73 71
diff --git a/bitbake/lib/bb/fetch2/ssh.py b/bitbake/lib/bb/fetch2/ssh.py
index e668b0d4b7..6047ee417a 100644
--- a/bitbake/lib/bb/fetch2/ssh.py
+++ b/bitbake/lib/bb/fetch2/ssh.py
@@ -43,7 +43,6 @@ IETF secsh internet draft:
43# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 43# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
44 44
45import re, os 45import re, os
46from bb import data
47from bb.fetch2 import FetchMethod 46from bb.fetch2 import FetchMethod
48from bb.fetch2 import FetchError 47from bb.fetch2 import FetchError
49from bb.fetch2 import logger 48from bb.fetch2 import logger
diff --git a/bitbake/lib/bb/fetch2/svn.py b/bitbake/lib/bb/fetch2/svn.py
index 3271be326c..3f172eec9b 100644
--- a/bitbake/lib/bb/fetch2/svn.py
+++ b/bitbake/lib/bb/fetch2/svn.py
@@ -28,7 +28,6 @@ import sys
28import logging 28import logging
29import bb 29import bb
30import re 30import re
31from bb import data
32from bb.fetch2 import FetchMethod 31from bb.fetch2 import FetchMethod
33from bb.fetch2 import FetchError 32from bb.fetch2 import FetchError
34from bb.fetch2 import MissingParameterError 33from bb.fetch2 import MissingParameterError
@@ -61,7 +60,7 @@ class Svn(FetchMethod):
61 60
62 # Create paths to svn checkouts 61 # Create paths to svn checkouts
63 relpath = self._strip_leading_slashes(ud.path) 62 relpath = self._strip_leading_slashes(ud.path)
64 ud.pkgdir = os.path.join(data.expand('${SVNDIR}', d), ud.host, relpath) 63 ud.pkgdir = os.path.join(d.expand('${SVNDIR}'), ud.host, relpath)
65 ud.moddir = os.path.join(ud.pkgdir, ud.module) 64 ud.moddir = os.path.join(ud.pkgdir, ud.module)
66 65
67 ud.setup_revisions(d) 66 ud.setup_revisions(d)
@@ -69,7 +68,7 @@ class Svn(FetchMethod):
69 if 'rev' in ud.parm: 68 if 'rev' in ud.parm:
70 ud.revision = ud.parm['rev'] 69 ud.revision = ud.parm['rev']
71 70
72 ud.localfile = data.expand('%s_%s_%s_%s_.tar.gz' % (ud.module.replace('/', '.'), ud.host, ud.path.replace('/', '.'), ud.revision), d) 71 ud.localfile = d.expand('%s_%s_%s_%s_.tar.gz' % (ud.module.replace('/', '.'), ud.host, ud.path.replace('/', '.'), ud.revision))
73 72
74 def _buildsvncommand(self, ud, d, command): 73 def _buildsvncommand(self, ud, d, command):
75 """ 74 """
diff --git a/bitbake/lib/bb/fetch2/wget.py b/bitbake/lib/bb/fetch2/wget.py
index 1cc445a426..0c61dfa20d 100644
--- a/bitbake/lib/bb/fetch2/wget.py
+++ b/bitbake/lib/bb/fetch2/wget.py
@@ -33,7 +33,6 @@ import logging
33import bb 33import bb
34import bb.progress 34import bb.progress
35import urllib.request, urllib.parse, urllib.error 35import urllib.request, urllib.parse, urllib.error
36from bb import data
37from bb.fetch2 import FetchMethod 36from bb.fetch2 import FetchMethod
38from bb.fetch2 import FetchError 37from bb.fetch2 import FetchError
39from bb.fetch2 import logger 38from bb.fetch2 import logger
@@ -84,9 +83,9 @@ class Wget(FetchMethod):
84 else: 83 else:
85 ud.basename = os.path.basename(ud.path) 84 ud.basename = os.path.basename(ud.path)
86 85
87 ud.localfile = data.expand(urllib.parse.unquote(ud.basename), d) 86 ud.localfile = d.expand(urllib.parse.unquote(ud.basename))
88 if not ud.localfile: 87 if not ud.localfile:
89 ud.localfile = data.expand(urllib.parse.unquote(ud.host + ud.path).replace("/", "."), d) 88 ud.localfile = d.expand(urllib.parse.unquote(ud.host + ud.path).replace("/", "."))
90 89
91 self.basecmd = d.getVar("FETCHCMD_wget") or "/usr/bin/env wget -t 2 -T 30 --passive-ftp --no-check-certificate" 90 self.basecmd = d.getVar("FETCHCMD_wget") or "/usr/bin/env wget -t 2 -T 30 --passive-ftp --no-check-certificate"
92 91