mirror of
https://git.yoctoproject.org/poky
synced 2026-06-02 01:19:52 +00:00
oeqa/sdk: use bash to execute SDK test commands
The commands only work with with bash. If /bin/sh is dash like in Debian, the command execution fails with errors like: Standard Output: /bin/sh: 5: export: --sysroot: bad variable name and all SDK tests fail. (From OE-Core rev: 274c22a1fd95418e4afb6633bb4b2e6debc4d7ea) Signed-off-by: Mikko Rapeli <mikko.rapeli@bmw.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
8356d0f38c
commit
29e2a3f5e8
@@ -8,5 +8,5 @@ from oeqa.core.case import OETestCase
|
|||||||
class OESDKTestCase(OETestCase):
|
class OESDKTestCase(OETestCase):
|
||||||
def _run(self, cmd):
|
def _run(self, cmd):
|
||||||
return subprocess.check_output(". %s > /dev/null; %s;" % \
|
return subprocess.check_output(". %s > /dev/null; %s;" % \
|
||||||
(self.tc.sdk_env, cmd), shell=True,
|
(self.tc.sdk_env, cmd), shell=True, executable="/bin/bash",
|
||||||
stderr=subprocess.STDOUT, universal_newlines=True)
|
stderr=subprocess.STDOUT, universal_newlines=True)
|
||||||
|
|||||||
@@ -42,7 +42,8 @@ class SDKBuildProject(BuildProject):
|
|||||||
def _run(self, cmd):
|
def _run(self, cmd):
|
||||||
self.log("Running . %s; " % self.sdkenv + cmd)
|
self.log("Running . %s; " % self.sdkenv + cmd)
|
||||||
try:
|
try:
|
||||||
output = subprocess.check_output(". %s; " % self.sdkenv + cmd, shell=True, stderr=subprocess.STDOUT)
|
output = subprocess.check_output(". %s; " % self.sdkenv + cmd, shell=True,
|
||||||
|
executable='/bin/bash', stderr=subprocess.STDOUT)
|
||||||
except subprocess.CalledProcessError as exc:
|
except subprocess.CalledProcessError as exc:
|
||||||
print(exc.output.decode('utf-8'))
|
print(exc.output.decode('utf-8'))
|
||||||
return exc.returncode
|
return exc.returncode
|
||||||
|
|||||||
Reference in New Issue
Block a user