aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlejandro Mery <amery@hanoverdisplays.com>2017-03-01 14:19:08 +0000
committerArmin Kuster <akuster808@gmail.com>2017-06-26 11:35:43 -0700
commit2a53b11d6cd99c05868c8d04e78c1c9ffd0a59ac (patch)
tree85bdd2bf3c34200756855d9641259e168fe6005d
parent1ec6d57e438cce13eab0be262eea23c37bf2f799 (diff)
downloadmeta-openembedded-contrib-2a53b11d6cd99c05868c8d04e78c1c9ffd0a59ac.tar.gz
meta-openembedded-contrib-2a53b11d6cd99c05868c8d04e78c1c9ffd0a59ac.tar.bz2
meta-openembedded-contrib-2a53b11d6cd99c05868c8d04e78c1c9ffd0a59ac.zip
gitver: fix try/except syntax for python3 support
https://www.python.org/dev/peps/pep-3110/ It's backward compatible with 2.6+ Signed-off-by: Alejandro Mery <amery@hanoverdisplays.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--meta-oe/classes/gitver.bbclass4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta-oe/classes/gitver.bbclass b/meta-oe/classes/gitver.bbclass
index e7b5155ee0..b677996ea6 100644
--- a/meta-oe/classes/gitver.bbclass
+++ b/meta-oe/classes/gitver.bbclass
@@ -27,13 +27,13 @@ def get_git_pv(path, d, tagadjust=None):
gitdir = os.path.abspath(os.path.join(d.getVar("S", True), ".git"))
try:
ver = gitrev_run("git describe --tags", gitdir)
- except Exception, exc:
+ except Exception as exc:
bb.fatal(str(exc))
if not ver:
try:
ver = gitrev_run("git rev-parse --short HEAD", gitdir)
- except Exception, exc:
+ except Exception as exc:
bb.fatal(str(exc))
if ver: