From: Robert Yang Date: Wed, 22 Aug 2018 08:36:53 +0000 (+0800) Subject: psplash: Clean up getstatusoutput usage X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3b9562e49fad08bde7eff868be27af6d4439cb29;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git psplash: Clean up getstatusoutput usage Replace usage of oe.utils.getstatusoutput() with direct subprocess calls. Signed-off-by: Robert Yang --- diff --git a/meta/recipes-core/psplash/psplash_git.bb b/meta/recipes-core/psplash/psplash_git.bb index aab2c0360de..3ad1ef48157 100644 --- a/meta/recipes-core/psplash/psplash_git.bb +++ b/meta/recipes-core/psplash/psplash_git.bb @@ -73,6 +73,8 @@ ALTERNATIVE_LINK_NAME[psplash] = "${bindir}/psplash" python do_compile () { import shutil + import subprocess + import shlex # Build a separate executable for each splash image workdir = d.getVar('WORKDIR') @@ -82,8 +84,7 @@ python do_compile () { outputfiles = d.getVar('SPLASH_INSTALL').split() for localfile, outputfile in zip(localfiles, outputfiles): if localfile.endswith(".png"): - outp = oe.utils.getstatusoutput('%s %s POKY' % (convertscript, os.path.join(workdir, localfile))) - print(outp[1]) + subprocess.call(shlex.split('%s %s POKY' % (convertscript, os.path.join(workdir, localfile)))) fbase = os.path.splitext(localfile)[0] shutil.copyfile("%s-img.h" % fbase, destfile) else: