diff options
-rw-r--r-- | bitbake/lib/bb/fetch2/git.py | 4 | ||||
-rw-r--r-- | meta/lib/oeqa/selftest/cases/signing.py | 4 |
2 files changed, 7 insertions, 1 deletions
diff --git a/bitbake/lib/bb/fetch2/git.py b/bitbake/lib/bb/fetch2/git.py index 82d7325188..ac996fa166 100644 --- a/bitbake/lib/bb/fetch2/git.py +++ b/bitbake/lib/bb/fetch2/git.py | |||
@@ -140,6 +140,10 @@ class Git(FetchMethod): | |||
140 | ud.proto = 'file' | 140 | ud.proto = 'file' |
141 | else: | 141 | else: |
142 | ud.proto = "git" | 142 | ud.proto = "git" |
143 | if ud.host == "github.com" and ud.proto == "git": | ||
144 | # github stopped supporting git protocol | ||
145 | # https://github.blog/2021-09-01-improving-git-protocol-security-github/#no-more-unauthenticated-git | ||
146 | ud.proto = "https" | ||
143 | 147 | ||
144 | if not ud.proto in ('git', 'file', 'ssh', 'http', 'https', 'rsync'): | 148 | if not ud.proto in ('git', 'file', 'ssh', 'http', 'https', 'rsync'): |
145 | raise bb.fetch2.ParameterError("Invalid protocol type", ud.url) | 149 | raise bb.fetch2.ParameterError("Invalid protocol type", ud.url) |
diff --git a/meta/lib/oeqa/selftest/cases/signing.py b/meta/lib/oeqa/selftest/cases/signing.py index 5c4e01b2c3..5b8f9bbd38 100644 --- a/meta/lib/oeqa/selftest/cases/signing.py +++ b/meta/lib/oeqa/selftest/cases/signing.py | |||
@@ -44,7 +44,9 @@ class Signing(OESelftestTestCase): | |||
44 | origenv = os.environ.copy() | 44 | origenv = os.environ.copy() |
45 | 45 | ||
46 | for e in os.environ: | 46 | for e in os.environ: |
47 | if builddir in os.environ[e]: | 47 | if builddir + "/" in os.environ[e]: |
48 | os.environ[e] = os.environ[e].replace(builddir + "/", newbuilddir + "/") | ||
49 | if os.environ[e].endswith(builddir): | ||
48 | os.environ[e] = os.environ[e].replace(builddir, newbuilddir) | 50 | os.environ[e] = os.environ[e].replace(builddir, newbuilddir) |
49 | 51 | ||
50 | os.chdir(newbuilddir) | 52 | os.chdir(newbuilddir) |