diff options
author | Ross Burton <ross.burton@intel.com> | 2016-07-21 15:59:40 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-07-25 23:47:00 +0100 |
commit | ce24d4c3632b71939ad198268a900ee823a89b27 (patch) | |
tree | a4ddb55722c7c625586282ddbea71a709f9eee05 /meta/lib/oe | |
parent | 5c0c1b8a64643ad7130b17b5dfce9cecffa6d962 (diff) | |
download | openembedded-core-ce24d4c3632b71939ad198268a900ee823a89b27.tar.gz openembedded-core-ce24d4c3632b71939ad198268a900ee823a89b27.tar.bz2 openembedded-core-ce24d4c3632b71939ad198268a900ee823a89b27.zip |
lib/oe/gpg_sign: fix output in error paths
oe.utils.getstatusoutput() is a wrapper for subprocess.getstatusoutput() which
uses Universal Newlines, so the output is a str() not bytes().
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/lib/oe')
-rw-r--r-- | meta/lib/oe/gpg_sign.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/meta/lib/oe/gpg_sign.py b/meta/lib/oe/gpg_sign.py index a8a478aa95..38eb0cb137 100644 --- a/meta/lib/oe/gpg_sign.py +++ b/meta/lib/oe/gpg_sign.py @@ -24,7 +24,7 @@ class LocalSigner(object): status, output = oe.utils.getstatusoutput(cmd) if status: raise bb.build.FuncFailed('Failed to export gpg public key (%s): %s' % - (keyid, output.decode("utf-8"))) + (keyid, output)) def sign_rpms(self, files, keyid, passphrase): """Sign RPM files""" @@ -39,7 +39,7 @@ class LocalSigner(object): status, output = oe.utils.getstatusoutput(cmd) if status: - raise bb.build.FuncFailed("Failed to sign RPM packages: %s" % output.decode("utf-8")) + raise bb.build.FuncFailed("Failed to sign RPM packages: %s" % output) def detach_sign(self, input_file, keyid, passphrase_file, passphrase=None, armor=True): """Create a detached signature of a file""" @@ -113,4 +113,3 @@ def get_signer(d, backend): return LocalSigner(d) else: bb.fatal("Unsupported signing backend '%s'" % backend) - |