diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2014-12-19 11:41:45 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-12-21 12:37:18 +0000 |
commit | a8143f33d3104adcd10968e3b05df2024e723f5a (patch) | |
tree | 96b4953af6b91322d9ad7f057d29c0d8ca37bfe4 /meta | |
parent | 657cff8a0f0e5db171b2ed9388a790ee0b135842 (diff) | |
download | openembedded-core-a8143f33d3104adcd10968e3b05df2024e723f5a.tar.gz openembedded-core-a8143f33d3104adcd10968e3b05df2024e723f5a.tar.bz2 openembedded-core-a8143f33d3104adcd10968e3b05df2024e723f5a.zip |
lib/oe/patch: fall back to patch if git apply fails
When PATCHTOOL = "git", git apply doesn't support fuzzy application, so
if a patch requires that it's better to be able to apply it rather than
just failing.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/lib/oe/patch.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/lib/oe/patch.py b/meta/lib/oe/patch.py index b085c9d6b5..788f465bd9 100644 --- a/meta/lib/oe/patch.py +++ b/meta/lib/oe/patch.py @@ -219,7 +219,11 @@ class GitApplyTree(PatchTree): return _applypatchhelper(shellcmd, patch, force, reverse, run) except CmdError: shellcmd = ["git", "--git-dir=.", "apply", "-p%s" % patch['strippath']] - return _applypatchhelper(shellcmd, patch, force, reverse, run) + try: + output = _applypatchhelper(shellcmd, patch, force, reverse, run) + except CmdError: + output = PatchTree._applypatch(self, patch, force, reverse, run) + return output class QuiltTree(PatchSet): |