diff options
author | Andre McCurdy <armccurdy@gmail.com> | 2018-06-05 12:13:50 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-06-15 17:57:30 +0100 |
commit | 783829427157b82dd021be345fe00afdf4d84a68 (patch) | |
tree | 46f95f4f37aabbcb5dc6101f222469cd25c914b6 /bitbake/lib/bb/fetch2/svn.py | |
parent | b054015357b2b03f308af00a41b29c649cbca171 (diff) | |
download | poky-783829427157b82dd021be345fe00afdf4d84a68.tar.gz |
bitbake: fetch2: unify the way fetchers determine DL_DIR and FETCHCMD
Currently there is quite some variation between the fetchers in terms
of how they determine the subdirectory within DL_DIR and the base
fetch command to run. Some rely on variables being set externally
(e.g. from bitbake.conf in oe-core), some respect these external
variables but provide fallback defaults and some use only hardcoded
internal values. Try to unify the approach used across the various
fetchers.
(Bitbake rev: efd5e35af4b08501c67e8b30f30d9457f6fdf610)
Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/fetch2/svn.py')
-rw-r--r-- | bitbake/lib/bb/fetch2/svn.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch2/svn.py b/bitbake/lib/bb/fetch2/svn.py index 3f172eec9b..ed70bcf8fb 100644 --- a/bitbake/lib/bb/fetch2/svn.py +++ b/bitbake/lib/bb/fetch2/svn.py | |||
@@ -49,7 +49,7 @@ class Svn(FetchMethod): | |||
49 | if not "module" in ud.parm: | 49 | if not "module" in ud.parm: |
50 | raise MissingParameterError('module', ud.url) | 50 | raise MissingParameterError('module', ud.url) |
51 | 51 | ||
52 | ud.basecmd = d.getVar('FETCHCMD_svn') | 52 | ud.basecmd = d.getVar("FETCHCMD_svn") or "/usr/bin/env svn --non-interactive --trust-server-cert" |
53 | 53 | ||
54 | ud.module = ud.parm["module"] | 54 | ud.module = ud.parm["module"] |
55 | 55 | ||
@@ -59,8 +59,9 @@ class Svn(FetchMethod): | |||
59 | ud.path_spec = ud.parm["path_spec"] | 59 | ud.path_spec = ud.parm["path_spec"] |
60 | 60 | ||
61 | # Create paths to svn checkouts | 61 | # Create paths to svn checkouts |
62 | svndir = d.getVar("SVNDIR") or (d.getVar("DL_DIR") + "/svn") | ||
62 | relpath = self._strip_leading_slashes(ud.path) | 63 | relpath = self._strip_leading_slashes(ud.path) |
63 | ud.pkgdir = os.path.join(d.expand('${SVNDIR}'), ud.host, relpath) | 64 | ud.pkgdir = os.path.join(svndir, ud.host, relpath) |
64 | ud.moddir = os.path.join(ud.pkgdir, ud.module) | 65 | ud.moddir = os.path.join(ud.pkgdir, ud.module) |
65 | 66 | ||
66 | ud.setup_revisions(d) | 67 | ud.setup_revisions(d) |