mirror of
https://git.yoctoproject.org/poky
synced 2026-06-14 17:29:59 +00:00
scripts: python3: decode subprocess output
stdeout and stderr content returned by subprocess API has different types in Python 3(bytes) and Python 2(string). Decoding it to 'utf-8' makes it unicode on both pythons. (From OE-Core rev: ae4d36375683b6cfd48af25bfca70b2e77f7ade5) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
a8314b9531
commit
4e36eeee77
@@ -45,7 +45,7 @@ def run_command(cmd):
|
||||
if pipe.returncode != 0:
|
||||
print("Execute command '%s' failed." % cmd)
|
||||
sys.exit(1)
|
||||
return output
|
||||
return output.decode('utf-8')
|
||||
|
||||
def get_cur_arch_dirs(workdir, arch_dirs):
|
||||
pattern = workdir + '/(.*?)/'
|
||||
|
||||
Reference in New Issue
Block a user