oeqa sdk cases: Skip SDK test cases when TCLIBC is newlib

Newlib generally requires additional components to function.  Skip the
cases where newlib is known to not work.

(From OE-Core rev: 99a5ca1c2c2b7b3193710bc681fbf05936025b5b)

Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit b9934755554e40d9980b90c3d541f4c702203561)
Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
This commit is contained in:
Mark Hatle
2024-07-26 11:22:36 -05:00
committed by Steve Sakoman
parent e1f0aceba1
commit d6771999e0
6 changed files with 26 additions and 0 deletions

View File

@@ -19,6 +19,10 @@ class BuildAssimp(OESDKTestCase):
"""
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("CMakeTest class: SDK doesn't contain a supported C library")
if not (self.tc.hasHostPackage("nativesdk-cmake") or
self.tc.hasHostPackage("cmake-native")):
raise unittest.SkipTest("Needs cmake")

View File

@@ -17,6 +17,11 @@ class BuildCpioTest(OESDKTestCase):
"""
Check that autotools will cross-compile correctly.
"""
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("AutotoolsTest class: SDK doesn't contain a supported C library")
def test_cpio(self):
with tempfile.TemporaryDirectory(prefix="cpio-", dir=self.tc.sdk_dir) as testdir:
tarball = self.fetch(testdir, self.td["DL_DIR"], "https://ftp.gnu.org/gnu/cpio/cpio-2.15.tar.gz")

View File

@@ -18,6 +18,10 @@ class EpoxyTest(OESDKTestCase):
Test that Meson builds correctly.
"""
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("MesonTest class: SDK doesn't contain a supported C library")
if not (self.tc.hasHostPackage("nativesdk-meson") or
self.tc.hasHostPackage("meson-native")):
raise unittest.SkipTest("EpoxyTest class: SDK doesn't contain Meson")

View File

@@ -18,6 +18,10 @@ class GalculatorTest(OESDKTestCase):
Test that autotools and GTK+ 3 compiles correctly.
"""
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("GTK3Test class: SDK doesn't contain a supported C library")
if not (self.tc.hasTargetPackage("gtk+3", multilib=True) or \
self.tc.hasTargetPackage("libgtk-3.0", multilib=True)):
raise unittest.SkipTest("GalculatorTest class: SDK don't support gtk+3")

View File

@@ -13,6 +13,11 @@ class BuildLzipTest(OESDKTestCase):
"""
Test that "plain" compilation works, using just $CC $CFLAGS etc.
"""
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("MakefileTest class: SDK doesn't contain a supported C library")
def test_lzip(self):
with tempfile.TemporaryDirectory(prefix="lzip", dir=self.tc.sdk_dir) as testdir:
tarball = self.fetch(testdir, self.td["DL_DIR"], "http://downloads.yoctoproject.org/mirror/sources/lzip-1.19.tar.gz")

View File

@@ -26,6 +26,10 @@ class GccCompileTest(OESDKTestCase):
os.path.join(self.tc.sdk_dir, f))
def setUp(self):
libc = self.td.get("TCLIBC")
if libc in [ 'newlib' ]:
raise unittest.SkipTest("GccCompileTest class: SDK doesn't contain a supported C library")
machine = self.td.get("MACHINE")
if not (self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine) or
self.tc.hasHostPackage("^gcc-", regex=True)):