mirror of
https://git.yoctoproject.org/poky
synced 2026-02-12 03:33:02 +01:00
Where there isn't a copyright statement, add one to make it explicit. Also add license identifiers as MIT if there isn't one. (From OE-Core rev: bb731d1f3d2a1d50ec0aed864dbca54cf795b040) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
33 lines
1.1 KiB
Python
33 lines
1.1 KiB
Python
#
|
|
# Copyright OpenEmbedded Contributors
|
|
#
|
|
# SPDX-License-Identifier: MIT
|
|
#
|
|
|
|
import os, tempfile
|
|
import time
|
|
from oeqa.sdk.case import OESDKTestCase
|
|
from oeqa.utils.subprocesstweak import errors_have_output
|
|
errors_have_output()
|
|
|
|
class BuildTests(OESDKTestCase):
|
|
"""
|
|
Verify that bitbake can build virtual/libc inside the buildtools.
|
|
"""
|
|
def test_libc(self):
|
|
with tempfile.TemporaryDirectory(prefix='bitbake-build-', dir=self.tc.sdk_dir) as testdir:
|
|
corebase = self.td['COREBASE']
|
|
|
|
self._run('. %s/oe-init-build-env %s' % (corebase, testdir))
|
|
with open(os.path.join(testdir, 'conf', 'local.conf'), 'ta') as conf:
|
|
conf.write('\n')
|
|
conf.write('DL_DIR = "%s"\n' % self.td['DL_DIR'])
|
|
|
|
try:
|
|
self._run('. %s/oe-init-build-env %s && bitbake virtual/libc' % (corebase, testdir))
|
|
finally:
|
|
delay = 10
|
|
while delay and (os.path.exists(testdir + "/bitbake.lock") or os.path.exists(testdir + "/cache/hashserv.db-wal")):
|
|
time.sleep(1)
|
|
delay = delay - 1
|