diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2012-01-19 13:59:15 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-01-19 14:32:04 +0000 |
commit | ce6c80a1e68c2af0b4b5fa27582ad9c9f119e5c1 (patch) | |
tree | 8f333beafbb2dbd682e1da8f5337a8657c901e81 /meta/classes | |
parent | d5b892467023d77d219ae05170c875f7b423aa78 (diff) | |
download | openembedded-core-ce6c80a1e68c2af0b4b5fa27582ad9c9f119e5c1.tar.gz openembedded-core-ce6c80a1e68c2af0b4b5fa27582ad9c9f119e5c1.tar.bz2 openembedded-core-ce6c80a1e68c2af0b4b5fa27582ad9c9f119e5c1.zip |
classes/patch: avoid backtrace when patch does not apply
We don't need to see a Python stack backtrace when a patch does not
apply, just the error output from patch, so trap these kinds of errors
and ensure that we display the message and fail the task and nothing
else.
Fixes [YOCTO #1143]
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/patch.bbclass | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/meta/classes/patch.bbclass b/meta/classes/patch.bbclass index 471c32bce2..1ea4bc5e02 100644 --- a/meta/classes/patch.bbclass +++ b/meta/classes/patch.bbclass @@ -155,7 +155,10 @@ python patch_do_patch() { patchset.Import({"file":local, "strippath": parm['striplevel']}, True) except Exception as exc: bb.fatal(str(exc)) - resolver.Resolve() + try: + resolver.Resolve() + except bb.BBHandledException as e: + bb.fatal(str(e)) } patch_do_patch[vardepsexclude] = "PATCHRESOLVE" |