diff options
author | Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com> | 2017-09-04 14:35:47 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-09-11 17:30:10 +0100 |
commit | 9ff023fb26f5f0ce19e757beda00ccc32c009b21 (patch) | |
tree | ae7347930866e918f8ee985f603057f8170e1a34 /meta | |
parent | d0a123ec564f6d36977e472f8bc63f9c050ee616 (diff) | |
download | openembedded-core-9ff023fb26f5f0ce19e757beda00ccc32c009b21.tar.gz openembedded-core-9ff023fb26f5f0ce19e757beda00ccc32c009b21.tar.bz2 openembedded-core-9ff023fb26f5f0ce19e757beda00ccc32c009b21.zip |
package_deb, ipk: improve subprocess output on package manager command
Redirecting stderr to stdout helps debugging issues, i.e instead of just
getting the return code, get also the error log from the pkg manger
This commit is in the way to figure out the root cause of [YOCTO #12012],
where dpkg-deb fails with a 2 return code and according to the man page,
there are multiple issues leading to the same code.
Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/package_deb.bbclass | 4 | ||||
-rw-r--r-- | meta/classes/package_ipk.bbclass | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/meta/classes/package_deb.bbclass b/meta/classes/package_deb.bbclass index 83baa6c21b..30605344f4 100644 --- a/meta/classes/package_deb.bbclass +++ b/meta/classes/package_deb.bbclass @@ -286,7 +286,9 @@ def deb_write_pkg(pkg, d): conffiles.close() os.chdir(basedir) - subprocess.check_output("PATH=\"%s\" dpkg-deb -b %s %s" % (localdata.getVar("PATH"), root, pkgoutdir), shell=True) + subprocess.check_output("PATH=\"%s\" dpkg-deb -b %s %s" % (localdata.getVar("PATH"), root, pkgoutdir), + stderr=subprocess.STDOUT, + shell=True) finally: cleanupcontrol(root) diff --git a/meta/classes/package_ipk.bbclass b/meta/classes/package_ipk.bbclass index d58b824d3a..ec90996184 100644 --- a/meta/classes/package_ipk.bbclass +++ b/meta/classes/package_ipk.bbclass @@ -244,7 +244,9 @@ def ipk_write_pkg(pkg, d): os.chdir(basedir) subprocess.check_output("PATH=\"%s\" %s %s %s" % (localdata.getVar("PATH"), - d.getVar("OPKGBUILDCMD"), pkg, pkgoutdir), shell=True) + d.getVar("OPKGBUILDCMD"), pkg, pkgoutdir), + stderr=subprocess.STDOUT, + shell=True) if d.getVar('IPK_SIGN_PACKAGES') == '1': ipkver = "%s-%s" % (d.getVar('PKGV'), d.getVar('PKGR')) |