summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa
Commit message (Collapse)AuthorAgeFilesLines
* oeqa: runtime: go: Increase test_go_compile/test_go_module timeoutMathieu Dubois-Briand2026-06-101-2/+2
| | | | | | | | | | | | | | | | | These tests tend do take a bit of time, and this is probably why they have been seen failing a few times in the past months. Rising the timeout from 5 to 10 minutes appears to help. Fixes [YOCTO #15999] (From OE-Core rev: c8a94dfc3a21403e8202a4adddbae9f3bd4a4549) Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (From OE-Core rev: 998ebfc77db4c8d7567d82560595e0994a310ae0) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* license.py: Drop visit_Str from SeenVisitor in selftestSunil Dora2026-05-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | ast.Str was deprecated in Python 3.8 and removed in Python 3.14. In [1], visit_Str was already removed from the LicenseVisitor subclasses (FlattenVisitor, ListVisitor) in oe/license.py since bitbake now requires Python 3.8+. However, the test-only SeenVisitor class in the selftest was missed at that time and still uses visit_Str/node.s. On Python 3.14, ast.Str is fully removed so visit_Str is never called, causing test_single_licenses to return [] instead of the expected license list. Replace visit_Str/node.s with visit_Constant/node.value in SeenVisitor. [1] https://git.openembedded.org/openembedded-core/commit/meta/lib/oe/license.py?id=6d3da37adbcaf5a7a3dade08f9d052571b195249 Fixes [YOCTO #16220] (From OE-Core rev: f8ac1b567d7c09ee45cb0d23fc9dd25987a76129) Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 8a5b019eec72676893507d018e7609745d2e3f49) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* selftest/gdbserver: replace shutil.unpack_archive with tarfile extractAlexander Kanavin2026-05-041-1/+3
| | | | | | | | | | | | | | | | This is a followup to https://lists.openembedded.org/g/openembedded-core/message/233609 as the same issue happened in a different selftest. [YOCTO #16195] (From OE-Core rev: 948028ca3466fb7071ee49000e847d6e886e349c) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit c7468e70c238b056acbe06ef722b62b02626db8f) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* selftest/minidebuginfo: extract files from tar archive using tarfile moduleAlexander Kanavin2026-05-041-2/+5
| | | | | | | | | | | | | | | | | | | | Python 3.14 added security checks around archive extraction, and by default will refuse to handle symlinks with absolute paths. It's possible to handle this using 'filter' argument, but it is not always available in older Python versions on various host distributions we need to support, so let's extract only the needed files directly using tarfile module. busybox is itself a symlink to busybox.nosuid, so both are extracted. [YOCTO #16195] (From OE-Core rev: 799e2124cdcb27bd924598619da61cbd11730b56) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit d52d00a3bb4a1ba93e88f1d24d8bb99d6aa321eb) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* lib/oeqa/utils/httpserver: use multiprocessing from bbRichard Purdie2026-05-041-1/+1
| | | | | | | | | | | | | | | | Fixes build with python-3.14 (and hence on Fedora 43) It was added to bitbake in 62be9113d98fccb347c6aa0a10d5c4ee2857f8b6 and oe-core now requires latest bitbake already, so we can use this. (From OE-Core rev: 2273e9ba2ffeea57620af576e3cd1e523e4d3fc3) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 3ed1cef082b8ef0fa05684f7a41f0842150811bd) [YC: bitbake commit was backported as 15d7448e04aa ("Use a "fork" multiprocessing context") in the 2.8(scarthgap) branch] Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* selftest/scripts: Update old git protocol referencesRichard Purdie2026-05-045-6/+6
| | | | | | | | | | | | | | | | | | | | | | git protocol accesses to our infrastructure are currently struggling and this has highlighted a number of places we're making those obsolete access forms. Update them to use https instead of the git protocol since it is preferred and more reliable. The devtool test needed quoting to handle the ';' in the url. The -f option to devtool also shows a deprecation warning so remove that. There were internal references to git protocol urls inside the nested git submodules test report, which means those repos need updating to use new git revisions. (From OE-Core rev: cbb3e323b74d4351c772a9bcd553008c31a220f0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 1ceba42623c5187d2f5a100d6a523abcdc75d34e) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* oeqa/sdk: Default to https git protocol for YP/OE reposYoann Congal2026-05-041-1/+1
| | | | | | | | | | | | | Following up on commit 139102a73d41 ("recipes: Default to https git protocol where possible"), > The recommendation from server maintainers is that the https protocol > is both faster and more reliable than the dedicated git protocol at this point. > Switch to it where possible. (cherry picked from commit 037f83803905fdbdf77ed325466abaa8a501d7ff) (From OE-Core rev: 296798981c9b8a1185a31146bb660eb0fa016ab2) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* oeqa/selftest/git-submodule-test: Default to https git protocol for YP/OE reposYoann Congal2026-05-041-2/+2
| | | | | | | | | | | | | | | | | | | Following up on commit 139102a73d41 ("recipes: Default to https git protocol where possible"), > The recommendation from server maintainers is that the https protocol > is both faster and more reliable than the dedicated git protocol at this point. > Switch to it where possible. Use ";protocol=https" for the parent git submodule and, also, update the SRCREV to point to a commit where submodules are reference through a https:// URL instead of a git:// one. Update the expected output of the archiver test. (cherry picked from commit 5c78db972f1b97ce67c8c461a2d389b9248793db) (From OE-Core rev: d839f4908ae6fb54c85bea5b658c23bfa9dc34da) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev>
* oeqa/selftest/wic: test recursive dir copy on ext partitionsDragomir, Daniel2026-02-271-0/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Extend the wic selftests to cover recursive directory copying into ext partitions. Previously, copying a directory into an ext partition could appear to succeed, but attempting to access the directory contents would fail with: -l: Ext2 inode is not a directory This was fixed in commit 4fc3b42774 ("wic/engine: fix copying directories into wic image with ext* partition"). This test now verifies that directories copied with "wic cp" into an ext4 partition: - are created with correct inode types - can be listed recursively with "wic ls" - preserve files and subdirectories - can be copied back out of the image without data loss A simple directory structure is used in this test: wic-test-cp-ext-dir/ ├── topfile.txt └── subdir/ └── subfile.txt (From OE-Core rev: 1e051c02bc05367d6b911ac9486403029f6f7cd8) Signed-off-by: Daniel Dragomir <daniel.dragomir@windriver.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 6de3d2602f4f4a8192d6a6040e89e814187dcf93) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Paul Barker <paul@pbarker.dev> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: oe-selftest: Add SPDX tests for kernel config and PACKAGECONFIGKamel Bouhara (Schneider Electric)2025-12-311-0/+57
| | | | | | | | | | | | | | | Add test_kernel_config_spdx and test_packageconfig_spdx to verify SPDX document generation includes kernel configuration and package feature metadata when enabled. (From OE-Core rev: a172a0e8d543796ee78bb66650726168352f1cdf) Signed-off-by: Kamel Bouhara (Schneider Electric) <kamel.bouhara@bootlin.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 2f0ab110d7521510c60e0493ef3cb021130758cd) Signed-off-by: Kamel Bouhara <kamel.bouhara@bootlin.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/sdk/buildepoxy: skip test in eSDKPeter Marko2025-11-261-0/+4
| | | | | | | | | | | | | | Currently meson inside eSDKs only works with fully populated eSDKs, but our testing uses minimal eSDKS, so skip the test if the eSDK is a minimal build. A bug has been filed to resolve this. This is minimal change extracted from OE-Core commit which has this only as a minor comment: 575e0bf52db0467d88af4b5fe467b682f10ca62a (From OE-Core rev: 7cfacaee1b3319e561036512a849e762d0f68a5e) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa: drop unnecessary dependency from go runtime testsPeter Marko2025-11-261-2/+0
| | | | | | | | | The tests do not use scp command, so openssh-scp is not needed. (From OE-Core rev: 4e10e7848cb10307f133f181b41563c995df032a) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa: fix package detection in go sdk testsPeter Marko2025-11-261-4/+4
| | | | | | | | | | | | | | | | | | | | | | | The test are skipped if architecture contains dash because TARGET_ARCH contains underscore while package name contains dash. Here the translation needs to be done. Note that poky distro default arch has dash: MACHINE="qemux86-64" TARGET_ARCH="x86_64" ERROR: Nothing PROVIDES 'go-cross-canadian-x86_64'. Close matches: gcc-cross-canadian-x86-64 gdb-cross-canadian-x86-64 go-cross-canadian-x86-64 TRANSLATED_TARGET_ARCH="x86-64" Quoting meta/classes-recipe/cross-canadian.bbclass: TRANSLATED_TARGET_ARCH is added into PN (From OE-Core rev: 82a46b70bfba7c4ce4fd20e2658b182b03e55037) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* go: remove duplicate arch map in sdk testOsama Abdelkader2025-11-261-26/+5
| | | | | | | | | | | | | | | ARCH_MAP is duplicating an existing map in meta/lib/oe/go.py use oe.go map_arch instead. (From OE-Core rev: c2ba36f41777d347fd5ffcd9b6862638e5f35a1b) (From OE-Core rev: 21f3a6c661307eab5530b51704c3a338013c9c5c) Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* go: extend runtime testOsama Abdelkader2025-11-262-0/+75
| | | | | | | | | | | | | | | | extend go runtime test with a simple test file, and simple go module test to validate go compilation and execution on target. (From OE-Core rev: e3b2b9170f76f4bbdc41ea6ba7bccffc17d01968) (From OE-Core rev: bda3e3711f84394423c15f48fb4e75258fec199a) Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* go: add sdk testOsama Abdelkader2025-11-261-0/+128
| | | | | | | | | | | | | | | | | - Add meta/lib/oeqa/sdk/cases/go.py with GoCompileTest and GoHostCompileTest classes - Test validates Go cross-compilation toolchain functionality - Includes native compilation, cross-compilation, and Go module support - Uses dynamic architecture detection for portability (From OE-Core rev: 17015f692a6bf3697a89db51bbc4673a5efa1497) (From OE-Core rev: 506f4e8c99b164673ba7d1c19e10d240f4df0376) Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* testsdk: allow user to specify which tests to runRoss Burton2025-11-262-2/+4
| | | | | | | | | | | | | | | | | | Following the usage of TEST_SUITES in testimage, add TESTSDK_SUITES to specify the list of tests to execute. By default the variable is empty, which means to run all discovered tests. This makes it easier to work on a single test without having to run all of the tests. (From OE-Core rev: 28d437c52c77889b2ede0fc2f2d6777c5b0a553d) (From OE-Core rev: a93e21419476658f24220193fb0183efeb7a184f) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa: spdx: Add tar test for SPDX 2.2Joshua Watt2025-11-141-2/+5
| | | | | | | | | | | | The base-files test for SPDX 2.2 did not give good coverage, since base-files doesn't have any dependencies. Add building tar as another test which more fully exercises the code (From OE-Core rev: 2c299c17ef1a97505fd7de8d3ebc9de25fb838fc) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* spdx 3.0: Rework how SPDX aliases are linkedJoshua Watt2025-11-141-13/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The SPDX code needs to be able to look up an Element by its SPDX ID, locating the file that (should) contain the SPDX ID and opening it for parsing. Previously, the code would do this be hashing each Element SPDX ID and Alias, and the creating a symbolic link to the file that contains the element with a name of the hash. This worked well as it was possible to look up any arbitrary SPDX ID or alias by simply hashing it and following the symbolic link to get the file. However, the down side of this approach is that it creates a lot of symbolic links, since it will make one or two per Element in the document. This can be a problem when using SPDX_INCLUDE_SOURCES, for example. This change reworks this strategy so that the only Element that gets a symbolic link based on the hash is the singular SpdxDocument that is create for each file. All other Elements are assigned an alias with a special prefix that encodes the hash of SpdxDocument alias. Thus, when attempting to look up an arbitrary alias, the code sees the special prefix, extract the hash, opens the file based on the symlink with that hash name, then finds the matching Element in the file. This drastically reduces the number of symbolic links by making only one per file. This also means that the custom link extension can be removed since it is now superfluous. (From OE-Core rev: 551433c7a1eddf5090c87a243ea104bf091992b0) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 838d64c09657ac53175737fc4e7fd6f01f3dcf47) Signed-off-by: Kamel Bouhara (Schneider Electric) <kamel.bouhara@bootlin.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* lib: oeqa: spdx: Add tests for extra optionsJoshua Watt2025-11-141-14/+104
| | | | | | | | | | | | | | | | | | Adds a test for several of the extra options provided by the SPDX classes. In particular, these are the options that can produce non-reproducible results, so are not enabled by default in OE core. This test takes care to configure the build so that the tests do run in a reproducible manner so that pre-built test objects can be pulled from sstate (From OE-Core rev: 72ee311d4f74499674a29223fb02d4e774097a54) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 14f534f15f7fe6362723d7f064d39783c5bd758f) Signed-off-by: Kamel Bouhara (Schneider Electric) <kamel.bouhara@bootlin.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/selftest: Add SPDX 3.0 include source case for work-shareHongxu Jia2025-11-141-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | Build gcc and check gcc-14.2.0/README in objset is available $ oe-selftest -r spdx.SPDX30Check.test_gcc_include_source ... 2024-10-26 01:24:57,063 - oe-selftest - INFO - test_gcc_include_source (spdx.SPDX30Check.test_gcc_include_source) 2024-10-26 01:28:24,204 - oe-selftest - INFO - The spdxId of gcc-14.2.0/README in gcc.spdx.json is http://spdx.org/spdxdocs/gcc-f2eaeb0d-b54b-53ba-899a-8c36c21139bf/88d5068ffd41e5ea6b4e0dd390b23bf499bb2b6674a41e09eaf2a887eced16c8/sourcefile/42 2024-10-26 01:28:26,369 - oe-selftest - INFO - ... ok 2024-10-26 01:28:33,315 - oe-selftest - INFO - ---------------------------------------------------------------------- 2024-10-26 01:28:33,316 - oe-selftest - INFO - Ran 1 test in 216.457s 2024-10-26 01:28:33,316 - oe-selftest - INFO - OK 2024-10-26 01:28:45,254 - oe-selftest - INFO - RESULTS: 2024-10-26 01:28:45,254 - oe-selftest - INFO - RESULTS - spdx.SPDX30Check.test_gcc_include_source: PASSED (209.31s) 2024-10-26 01:28:45,260 - oe-selftest - INFO - SUMMARY: 2024-10-26 01:28:45,260 - oe-selftest - INFO - oe-selftest () - Ran 1 test in 216.457s 2024-10-26 01:28:45,260 - oe-selftest - INFO - oe-selftest - OK - All required tests passed (successes=1, skipped=0, failures=0, errors=0) (From OE-Core rev: 45f3039a4f0fcea208e317ed7134458f7aa7a4cc) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Reviewed-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit ccd6dde301dc8c45c8f901ebd4676b488d638b08) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest: spdx: Add SPDX 3.0 test casesJoshua Watt2025-11-141-9/+124
| | | | | | | | | | | | Adds test cases for SPDX 3.0. Reworks the SPDX 2.2 test setup so it can also be run even if the default is SPDX 3.0 (From OE-Core rev: e182f76a866d4d750d2baf7b56ffebead5264de2) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit b1d2309b3ab0fd8b0d8c4dfa59f50c85074bbd3b) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest/spdx: Fix for SPDX_VERSION additionRichard Purdie2025-11-141-1/+2
| | | | | | | | | | Update the test for the addition of SPDX_VERSION to the deploy path. (From OE-Core rev: d75bfbaf69292f80cacc5b8d6cbff03418a34ebc) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 055e8c21908127722abad9e992d6408d8697a119) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/selftest/devtool: Update after upstream repo changesRichard Purdie2025-11-141-4/+4
| | | | | | | | | | | | | | | The upstream changed the branch name, moving to archive/ so we need to update too. Take the opportunity to match the new location too to avoid the redirect. We could use a different branch but upstream would probably eventually rename that too so this may last longer. (From OE-Core rev: 1e0a64a1890a62e130595f46d93c8d08af9170f5) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 478a645bad150f04dee1b0085c4542c2eefe7007) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ping: don't bother trying to ping localhostMichael Haener2025-10-241-0/+7
| | | | | | | | | | | | | | | | | | | | | If SLIRP is being used instead of TAP for networking to the guest then the target IP will be localhost. There's no point in pinging localhost to see if the target is up but whilst you'd think it is harmless, in some containers ping doesn't actually have enough rights to work: ping: socktype: SOCK_RAW ping: socket: Operation not permitted ping: => missing cap_net_raw+p capability or setuid? Look at the target address and if it's localhost or 127.0.0.* return immediately. (Backport from OE-Core rev: a06ef43d2a50e16c32bd6edbdc7b32c3528687d5) (From OE-Core rev: 649147913e89cd8f7390cb17cd0be94c9710ffa6) Signed-off-by: Michael Haener <michael.haener@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/sdk/cases/buildcpio.py: use gnu mirror instead of main serverSteve Sakoman2025-10-131-1/+1
| | | | | | | | | | | | | | | ftp.gnu.org is the main server of the GNU project, however download speed can vary greatly based on one's location. Using ftpmirror.gnu.org should redirect the request to the closest up-to-date mirror, which should result sometimes in significantly faster download speed, depending on one's location. This should also distribute the traffic more across the mirrors. This information was sourced from https://www.gnu.org/prep/ftp.html (From OE-Core rev: b0ce480eca6397fab71082ed202c3cf9dd02456f) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest/cases/meta_ide.py: use use gnu mirror instead of main serverSteve Sakoman2025-10-131-1/+1
| | | | | | | | | | | | | | | ftp.gnu.org is the main server of the GNU project, however download speed can vary greatly based on one's location. Using ftpmirror.gnu.org should redirect the request to the closest up-to-date mirror, which should result sometimes in significantly faster download speed, depending on one's location. This should also distribute the traffic more across the mirrors. This information was sourced from https://www.gnu.org/prep/ftp.html (From OE-Core rev: aa7ff5a115f55c092f8ca5badad63734c8f4f5b7) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* default-distrovars.inc: Fix CONNECTIVITY_CHECK_URIS redirect issueDeepak Rathore2025-09-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The default CONNECTIVITY_CHECK_URIS uses "https://yoctoproject.org/connectivity.html" which redirect to "https://www.yoctoproject.org/connectivity.html". Some network configurations with proxies or restricted internet access don't handle HTTP redirects properly during the sanity check phase, causing build failures with: ERROR: OE-core's config sanity checker detected a potential misconfiguration. Either fix the cause of this error or at your own risk disable the checker (see sanity.conf). Following is the list of potential problems / advisories: Fetcher failure for URL: 'https://yoctoproject.org/connectivity.html'. URL doesn't work. Updated the default URL to use the final destination directly to avoid redirect-related connectivity check failures. Also updated SDK test cases in https.py to use the corrected URL for consistency. (From OE-Core rev: bd624ebbcf4e6d7a24c4ab232ca2e138b1ac3433) Signed-off-by: Deepak Rathore <deeratho@cisco.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 60cdf960a3560f391babd559737f1afb31fb2c5c) Signed-off-by: Deepak Rathore <deeratho@cisco.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* sstatetests: Switch to new CDNRichard Purdie2025-06-051-1/+1
| | | | | | | | | | | The project is switching the way handle our CDN provision of sstate objects, update the URL accordingly. (From OE-Core rev: d1b64f190c1686f081f5ba2c4f2b320048f6a514) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit fea96974f1ee6ae6dceb39e3ca8157797d81586c) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest/rust: correctly form the PATH environment variableAlexander Kanavin2025-02-121-3/+2
| | | | | | | | | | | | | | | | | | | | There were two issues here: - the path to native python was not included, so the test suite was running with host python, causing failures due to host python being given native libraries: https://autobuilder.yoctoproject.org/typhoon/#/builders/148/builds/1711/steps/12/logs/stdio (rust recipe uses native python throughout) - tmp/hosttools was listead ahead of native-sysroot/usr/bin (From OE-Core rev: 72156282059aa5a013a386eb95f89dc38726326e) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit aec96b5aec8d6b4a5ae8a719ca05bb727a6197cb) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/selftest/rust: skip on all MIPS platformsRoss Burton2025-02-121-5/+3
| | | | | | | | | | | | | | | | | | | | | As per "The rustc book"[1], mips*-unknown-linux-* are "tier 3" targets: Tier 3 targets are those which the Rust codebase has support for, but which the Rust project does not build or test automatically, so they may or may not work. We already skip qemumips in this selftest, but we're now also seeing failures with qemumips64 so refactor the test to skip all machines where the architecture is mips or mips64. [1] https://doc.rust-lang.org/nightly/rustc/platform-support.html (From OE-Core rev: 681f5ea8d6a5050aebfb1f656da9ba679433e366) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 177e268811c04260923ac4b16fa047315304add0) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/sdk/context: fix for gtk3 test failure during do_testsdkHarish Sadineni2025-02-121-5/+7
| | | | | | | | | | | | | | | | The do_testsdk for lib32-core-image-sato aborts with below error: configure: error: Package requirements (gtk+-3.0) were not met: No package 'gtk+-3.0' found Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. This causes due to an absolute path name in 'sdk_env', which is now stripped to have only the environment name. Backport from oe-core master: https://git.openembedded.org/openembedded-core/commit/?id=386e4132a9ced75599d92610cf5c0e8fe907c3b6 (From OE-Core rev: 83c3e40e2361d771a724062e38a1349b87059c75) Signed-off-by: Harish Sadineni <Harish.Sadineni@windriver.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oe-selftest: devtool ide-sdk use modify debug-buildAdrian Freihofer2025-02-031-1/+1
| | | | | | | | (From OE-Core rev: 1528d6aa060811402eaecb1a9fe16bfec0417c98) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* rust: build the default set of toolsAlexander Kanavin2025-01-261-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Setting it explicitly replaces rust's default choice which is rustdoc (needed for example in selftests and otherwise expected to be present in typical rust installations): https://github.com/rust-lang/rust/blob/master/config.example.toml#L320 This addresses some of the rust selftest failures but not all. Help is appreciate to restore the selftest. Unfortunately, this also breaks rust reproducibility (or rather exposes that it was never properly fixed, as explained here: https://lists.openembedded.org/g/openembedded-core/message/199288 ) (From OE-Core rev: 4d739fe248d1023eb2c3c040fc4d33273dd16bc1) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 58eaf2ee6c0809bf0a0d3c1d177e62bda7241651) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/ssh: allow to retrieve raw, unformatted ouputAlexis Lothoré2025-01-241-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | The ssh target is currently well tailored to easily retrieve textual output from a command run on a remote target. It could also be used to retrieve raw data from a command run onto a remote target (for example, to feed this data directly to another program), but it currently suffers two minor issues preventing such use case: - stderr is piped to stdout, so any error log will be mixed in the program output - the final output is decoded as utf-8 and stripped Allow to return the raw, unmodified output by adding an optional "raw" parameter. Keep it to False by default to preserve the current behavior. When enabled, do not return a string but the raw output as bytes. (From OE-Core rev: 8d05dc6e2284b7ed7c32a8215b9c8bf6f7dabf00) (From OE-Core rev: d09187db648053a763036a5209efd584b352cf31) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/utils/gitarchive: Return tag name and improve exclude handlingRichard Purdie2024-12-091-1/+3
| | | | | | | | | | | | | Tweak the gitarchive exclude handling not to error if excluded files don't match. Also return the tagname created so that other code can then use it. (From OE-Core rev: 0a5b4fabf8bf9b559295bb4d2583809ca11522f4) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 1adba3430faffdf6217b6a00533a3b48a9388abc) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* resulttool: Use single space indentation in json outputRichard Purdie2024-12-091-1/+1
| | | | | | | | | | | | | Using 4 space indentation in resulted in hundreds of megabytes of extra file size in general use. Reduce this to make filesizes more managable and reduce the processing cost. Some level of indentation and spacing does make the files more readable and allows use of git diff so we need to retain some of it. (From OE-Core rev: 03fef3a99186863a0c460bd89bad40f2360a6930) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit a274cdcaf852cca9497f0358f44dda99c06aacbe) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest/reproducible: Clean up pathnamesRichard Purdie2024-12-091-1/+1
| | | | | | | | | | | | | | | | | | | There are several problems with these paths. Firstly they contain full system paths which depend upon where the test was run. These are pretty pointless and just take up a lot of space making the results files large. Secondly, they contain the same path twice. The reference and target path will always be the same thing in two different locations. Strip off the prefix and remove the duplication. This does change the output data but that can't really be avoided. It does shrink the results data and makes it more readable. (From OE-Core rev: 44ee8f69db5e008b5ac5e0dbf390bb4fcf704f07) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 81a44de36e864b08687451fd85aeba7c529fd7f7) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* selftest/reproducible: Drop rawlogsRichard Purdie2024-12-091-6/+0
| | | | | | | | | | | | | | | The "rawlogs" data consists of a long string of results data which is already in a structured data format. I can't see this is adding much value in duplciating the data but it does create a huge string with a lot of long problematic pathnames and inflates the results data size. I suggest we drop this data as obsolete and not necessary. (From OE-Core rev: 296f64cbf83c40759b368526335502a6b130aa14) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 5b2c70fab2ffa409b861d83f048b65d458d03a90) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* rootfs: Ensure run-postinsts is not uninstalled for ↵Gassner, Tobias.ext2024-12-061-1/+40
| | | | | | | | | | | | | | | | | | | read-only-rootfs-delayed-postinsts This patch ensures that pkg_postinst_ontarget task is executed for read only rootfs when read-only-rootfs-delayed-postinsts is set as IMAGE_FEATURES. The issue was that run-postinsts could be uninstalled at the end of rootfs construction and that shouldn't happen for the delayed usecase. In addition to the fix, a test in meta/lib/oeqa/selftest/cases/overlayfs.py testing the fix has been implemented. (From OE-Core rev: e0c4f2f69723f64a29ba35c4de5fb1a7c79ef718) Signed-off-by: Gassner, Tobias.ext <tobias.gassner.ext@karlstorz.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> (cherry picked from commit 60f587475dda99eaa07848880058b69286b8900e) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* qemurunner: Clean up serial_lock handlingRichard Purdie2024-11-261-5/+6
| | | | | | | | | | | | Avoid "RuntimeError: release unlocked lock" since the lock shouldn't be locked even in the error path. Add a try/finally path to ensure this. (From OE-Core rev: 78f86c946d37d15b044be158e22e9853009cae27) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit b0732ee009ca47580d1d2ad75334f4aa50e6efd5) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ssh: Fix incorrect timeout fixRichard Purdie2024-11-261-2/+2
| | | | | | | | | | | I'd meant to change the command timeout in the previous change, fix the correct one. (From OE-Core rev: 419c96d17205fc9485869ab0fc1f27de52c31789) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit bb991988cb23be2c8947171726ada321f27e6eed) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ssh: Rework ssh timeoutRichard Purdie2024-11-261-2/+2
| | | | | | | | | | | | | | | | | | After the changes to improve this test, we keep seeing image testing ssh failures, particularly on mips. It looks like part of the problem is that on a loaded system, 5s is too short for mips to reliably establish an ssh connection. I've seen logs where it keeps timing out and fails to work, then the debug code successfully uses ssh later after everything else fails. Change the timings/retries to give slow platforms enough time to respond. (From OE-Core rev: 55780565831a1a5fa292d82b2b04943fb9ddc82e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit ba64ccf3ad6e40461219b72d60eb0fe5cb38fddd) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* meta-ide-support: Mark recipe as MACHINE-specificPaul Barker2024-10-181-2/+2
| | | | | | | | | | | | | | | | | | meta-ide-support:do_write_test_data dumps the bitbake data dictionary to a file using export2json(). As this obviously includes the value of MACHINE, and other MACHINE-specific variables, the recipe needs to be marked as MACHINE-specific. RP: Note that this patch does change the name of the environment script since it is no longer package arch specific but machine arch specific. [RP: Fix selftest to reference new environment file] (From OE-Core rev: bec6b535c9a817a5ed51453bcb9ecae0b81a8590) Signed-off-by: Paul Barker <paul.barker.ct@bp.renesas.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 3be2bc8a9b0c9d6a178329c8b451a6bedf255d6c) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/postactions: fix exception handlingAlexis Lothoré2024-09-251-1/+1
| | | | | | | | | | | | | | | | | The current exception handler in list_and_fetch_failed_tests_artifacts expects a non-exisiting variable and then fail to display the original exception message since it raises a new one. The issue has been introduced with commit 6e80b2ab660e ("oeqa/utils/postactions: transfer whole archive over ssh instead of doing individual copies"). Now that tests artifacts are now handled individually, there's no point of trying to print individual names in the exception. (From OE-Core rev: 60a7448abce091eb8c1cb953058fade0beb8b670) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit a50e72bb64fb8b0d14c23164eaeeabd9c271ac19) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ssh: increase the number of attemptsJon Mason2024-09-091-1/+1
| | | | | | | | | | | | | Under high load, the ssh test is hitting the amount of retries. Increase it to 20 to avoid this issue. This would increase the maximum failure time from 50 seconds (5 * 10) to 100 seconds. (From OE-Core rev: 4581b5793f310d2f1f0c80bfe1a5f8743416c4fc) Signed-off-by: Jon Mason <jdmason@kudzu.us> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit c796438eec5dd6b4671b798f85506bc89ff402ab) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/utils/postactions: transfer whole archive over ssh instead of doing ↵Alexis Lothoré2024-08-261-10/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | individual copies Fixes [YOCTO 15536] The postactions retrieval actions currently rely on scp executed individually on any file or directory expanded from TESTIMAGE_FAILED_QA_ARTIFACTS. Unfortunately, symlinks are not preserved with this mechanism, which lead to big storage space consumption. Things may go even worse if those symlinks create some circular chains. This mechanism then needs to be updated to preserve symlinks instead of following them during copy. There are multiple ways to do it: - create a local archive on the target and execute scp on this file - use rsync instead of scp for all files - create an archive and pipe it to ssh instead of storing it onto the target The first solution may create pressure on targets storage space, while the second assumes that rsync is installed on the target, which may not be true. So the third one is a compromise: tar is very likely present, at least through busybox, and no disk space is used on the target. Replace the current per-file scp call by a single call to tar run on the target. Retrieve the generated compressed archive directly from SSH output, and feed it to another tar process but on host, to uncompress and extract it at the same place as before. (From OE-Core rev: 8b5c66c91d94f4c8521fe9443e65d86063dba5e5) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 4aeb10aa38efc6768928fbb74985e36e972b8e46) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/selftest/reproducibile: Explicitly list virtual targetsRichard Purdie2024-08-261-1/+2
| | | | | | | | | | | | | | | | | | We're seeing reproducibility failures where some packages don't appear in the "from sstate" builds. The common factor is these are all recipes with PROVIDES = "virtual/XXX". In a full build from scratch, these are build but in a build from sstate, there are situations where they aren't. For now, to try and keep builds working, work around the problem until we can better look into the problem. It is likely recent taskhash imrovements have caused this to occur more regularly. (From OE-Core rev: 9f0eba6aba5e9b37975f86556c1234b145a0859e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 68086a333acc54390e4e589ef928dc90da3edb48) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ssh: check for all errors at the endJon Mason2024-08-261-3/+3
| | | | | | | | | | | | | | | | | With the retry for the -SIGTERM, it is possible to still see that error after the 5th attempt and mark the run a success. Check for any non-zero status in the final check and error out to close the gap. While there, make the error print match the one above and be a little more verbose. Also, I'm seeing it take roughly 6 attempts on my local (very slow) system to pass. So, increasing the number of attempts to 10. (From OE-Core rev: 52a67132d4d7e656a39d87c03b1c6162018e8908) Signed-off-by: Jon Mason <jdmason@kudzu.us> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 3c3ebe591eef6e0479d623ec2237cfea16db5c80) Signed-off-by: Steve Sakoman <steve@sakoman.com>
* oeqa/runtime/ssh: In case of failure, show exit code and handle -15 (SIGTERM)Richard Purdie2024-08-261-2/+5
| | | | | | | | | | | | | Ensure we show the failing exit code in case of failures. We're seeing autobuilder failures with -15 (SIGTERM) which is probably from slow boot/init. Retry in these cases for now. (From OE-Core rev: 1bd6b0e29650c34652c1027b6975eb8620a73c55) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 127d3bd8d5509ae17e359c1365859fd362ffc74f) Signed-off-by: Steve Sakoman <steve@sakoman.com>