summaryrefslogtreecommitdiffstats
path: root/meta/lib
AgeCommit message (Collapse)Author
2020-06-12buildhistory: Add simplistic file move detectionRichard Purdie
We'd like to use buildhistory more during patch review however its proving hard, particularly where whole subtrees of files move, such as a kernel version upgrade, or where a software module moves include directory. This adds file rename matching which covers our common case of library moves, kernel upgrades and more. A new test case is also added so that someone in the future can change the code and test the logic is still doing the expected things. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-10wic: Fix --extra-space argument handlingJoshua Watt
467f84e12b ("wic: Add --offset argument for partitions") broke the --extra-space argument handling in wic. Fix the option and add a unit test for the argument. Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-06archiver: Speed up testsPaul Barker
When running tests locally without the advantage of a populated sstate cache, the archiver tests can take an unnecessarily long time. Using different target recipes can speed things up a lot by reducing the number of dependencies that are built. For the test case test_archiver_srpm_mode we can still test the conditions described in bug #11121 by using a target recipe that is known to inherit the nopackages class as well as a more normal recipe, instead of having to compute all the depepndencies of core-image-sato. Before: archiver.Archiver.test_archiver_allows_to_filter_on_recipe_name: PASSED (20.50s) archiver.Archiver.test_archiver_filters_by_type: PASSED (14.16s) archiver.Archiver.test_archiver_filters_by_type_and_name: PASSED (79.08s) archiver.Archiver.test_archiver_mode_configured: PASSED (558.19s) archiver.Archiver.test_archiver_mode_diff: PASSED (14.59s) archiver.Archiver.test_archiver_mode_dumpdata: PASSED (14.41s) archiver.Archiver.test_archiver_mode_mirror: PASSED (14.02s) archiver.Archiver.test_archiver_mode_mirror_combined: PASSED (19.99s) archiver.Archiver.test_archiver_mode_mirror_excludes: PASSED (14.24s) archiver.Archiver.test_archiver_mode_mirror_gitsm: PASSED (13.47s) archiver.Archiver.test_archiver_mode_mirror_gitsm_shallow: PASSED (22.15s) archiver.Archiver.test_archiver_mode_original: PASSED (14.15s) archiver.Archiver.test_archiver_mode_patched: PASSED (14.57s) archiver.Archiver.test_archiver_mode_recipe: PASSED (14.56s) archiver.Archiver.test_archiver_srpm_mode: PASSED (83.03s) oe-selftest () - Ran 15 tests in 911.905s After: archiver.Archiver.test_archiver_allows_to_filter_on_recipe_name: PASSED (23.66s) archiver.Archiver.test_archiver_filters_by_type: PASSED (15.16s) archiver.Archiver.test_archiver_filters_by_type_and_name: PASSED (15.33s) archiver.Archiver.test_archiver_mode_configured: PASSED (15.94s) archiver.Archiver.test_archiver_mode_diff: PASSED (15.79s) archiver.Archiver.test_archiver_mode_dumpdata: PASSED (15.39s) archiver.Archiver.test_archiver_mode_mirror: PASSED (15.28s) archiver.Archiver.test_archiver_mode_mirror_combined: PASSED (21.22s) archiver.Archiver.test_archiver_mode_mirror_excludes: PASSED (15.11s) archiver.Archiver.test_archiver_mode_mirror_gitsm: PASSED (13.61s) archiver.Archiver.test_archiver_mode_mirror_gitsm_shallow: PASSED (23.21s) archiver.Archiver.test_archiver_mode_original: PASSED (14.87s) archiver.Archiver.test_archiver_mode_patched: PASSED (15.50s) archiver.Archiver.test_archiver_mode_recipe: PASSED (15.62s) archiver.Archiver.test_archiver_srpm_mode: PASSED (20.66s) oe-selftest () - Ran 15 tests in 257.170s Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-05archiver: Capture git submodules in mirror archiverPaul Barker
Using the new Fetch.expanded_urldata() function we can get URL data for all git submodules. Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04glibc: move ld.so.conf back to main packageRasmus Villemoes
There are cases where one doesn't want ldconfig on target (e.g. for read-only root filesystems, it's rather pointless), yet one still needs ld.so.conf to be present at image build time: When some recipe installs libraries to a non-standard location, and dutifully drops in a file in /etc/ld.so.conf.d/foo.conf, we need the ld.so.conf containing the include /etc/ld.so.conf.d/*.conf stanza to get those other locations picked up. So change the packaging logic so that there's always an ld.so.conf present when the build-time ldconfig runs. The ld.so.conf and ld.so.conf.d/*.conf files don't take up much room (at least not compared to the 700K binary ldconfig), and they might be needed in case ldconfig is installable, so leave them alone. In case of a read-only rootfs, one could add some logic to remove them if one really wants to shave those few dozens of bytes off. While here, fix typos in the bb.note (add spaces) so one can just copy-paste the line from the log-file and redo the command. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04oe-selftest: Recursively patch test case pathsPaul Barker
This ensures that builddir is updated correctly to point to the new selftest build directory when we're given a list of test suites instead of a list of test cases. Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04oe-selftest: Support verbose log outputPaul Barker
Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04oe-selftest: Allow overriding the build directory used for testsPaul Barker
This may be useful if the parent directory of the original builddir is not writable, on a lower performance drive, etc. Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04archiver: Fix test case for srpm archiver modePaul Barker
We can't assume that rpm packaging will always be enabled when running oe-selftest. In particular when using nodistro instead of poky this is not enabled by default. Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04wic: Add --offset argument for partitionsJoshua Watt
Add support for an --offset argument when defining a partition. Many SoCs require that boot partitions be located at specific offsets. Prior to this argument, most WKS files were using the --align attribute to specify the location of these fixed partitions but this is not ideal because in the event that the partition couldn't be placed in the specified location, wic would move it to the next sector with that alignment, often preventing the device from booting. Unlike the --align argument, wic will fail if a partition cannot be placed at the exact offset specified with --offset. Changes in V2: * Fixed a small typo that prevented test_fixed_size_error from passing Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-04oeqa/targetcontrol: Rework exception handling to avoid warningsRichard Purdie
We're seeing: WARNING: bitbake/lib/bb/cookerdata.py:136: ResourceWarning: unclosed file <_io.FileIO name='tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/qemurunner_log.20200601181912' mode='ab' closefd=True which can only be caused by the qemu.stop() method not being called. Tweak the error handling to fix the blanket exception handler which is likely meaning this function isn't getting called. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03apt: update to 1.8.2.1Alexander Kanavin
I took the opportunity to rewrite the recipe from scratch; there was just too much baggage in it. Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03meta-selftest: add test for .patch file with long filename and without subjectMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03Revert "lib/oe/patch: fix handling of patches with no header"Martin Jansa
* This reverts commit d9971f5dc8eb7de551fd6f5e058fd24770ef5d78. * With the missing Subject line fixed in GitApplyTree.prepareCommit() we should be able to revert, the fix which was trying to help it by parsing GitApplyTree.patch_line_prefix ("%% original patch:") also from Subject line, now GitApplyTree.patch_line_prefix should always end on separate line which is then skipped when copying the lines to resulting patch, see original commit message from Paul: lib/oe/patch: fix handling of patches with no header If a patch applied by a recipe has no header and we turn the recipe's source into a git tree (when PATCHTOOL = "git" or when using devtool extract / modify / upgrade), the commit message ends up consisting only of the original filename marker ("%% original patch: filename.patch"). When we come to do turn the commits back into a set of patches in extractPatches(), this first line ends up in the "Subject: " part of the file, but we were ignoring it because the line didn't start with the marker text. The end result was we weren't able to get the original patch name. Strip off any "Subject [PATCH x/y]" part before looking for the marker text to fix. This caused "devtool modify openssl" followed by "devtool update-recipe openssl" (without any changes in-between) to remove version-script.patch because that patch has no header and we weren't able to determine the original filename. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03lib/oe/patch: GitApplyTree: save 1 echo in commit-msg hookMartin Jansa
* also remove the extra blank lines which is often added to patches when refreshed with devtool (GitApplyTree.patch_line_prefix lines are ignored when refreshing .patch files, but newly added blank lines aren't - the leading blank line wasneeded for patches with just the subject line (to prevent the GitApplyTree.patch_line_prefix line ending appended to the commit summary), but we can add it in prepareCommit instead Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03lib/oe/patch: prevent applying patches without any subjectMartin Jansa
* this was discovered with $ devtool finish --force-patch-refresh where it was removing some patches and replacing them with patch in filename called "patch:" e.g. this .patch file: https://github.com/OSSystems/meta-browser/blob/311067d2d8a50cee5c836892606444f63f2bb3ab/dynamic-layers/rust-layer/recipes-browser/firefox/firefox/fixes/fix-camera-permission-dialg-doesnot-close.patch confuses devtool which results to create new .patch file called "patch:" $ devtool finish --force-patch-refresh firefox meta-browser NOTE: Starting bitbake server... WARNING: Host distribution "ubuntu-20.04" has not been validated with this version of the build system; you may possibly experience unexpected failures. It is recommended that you use a tested distribution. Loading cache: 100% |###################################################################################################################################################################################################################################| Time: 0:00:00 Loaded 2480 entries from dependency cache. Parsing recipes: 100% |#################################################################################################################################################################################################################################| Time: 0:00:00 Parsing of 1718 .bb files complete (1717 cached, 1 parsed). 2480 targets, 68 skipped, 0 masked, 0 errors. Summary: There was 1 WARNING message shown. INFO: Updating patch 0001-Bug-1554949-Fix-WebRTC-build-failure-with-newer-linu.patch ... INFO: Updating patch pre-generated-old-configure.patch INFO: Adding new patch patch: INFO: Updating recipe firefox_68.0esr.bb INFO: Removing file /OE/build/test-oe-build-time/poky/meta-browser/dynamic-layers/rust-layer/recipes-browser/firefox/firefox/fixes/fix-camera-permission-dialg-doesnot-close.patch INFO: Cleaning sysroot for recipe firefox... INFO: Leaving source tree /OE/build/test-oe-build-time/poky/build/workspace/sources/firefox as-is; if you no longer need it then please delete it manually this looked like incorrect parsing of the git format-patch files exported from workspace/sources (the git format-patch version of fix-camera-permission-dialg-doesnot-close.patch starts like this: $ head 0008-original-patch-fix-camera-permission-dialg-doesnot-c.patch From 37dfa11961b48024bedcfb9336f49107c9535638 Mon Sep 17 00:00:00 2001 From: Takuro Ashie <ashie@clear-code.com> Date: Mon, 20 Aug 2018 10:16:20 +0900 Subject: [PATCH 08/34] %% original patch: fix-camera-permission-dialg-doesnot-close.patch so first I've modified GitApplyTree.extractPatches() to be able to parse the original patch name correctly even in this case where subject is wrapped, but then it still wasn't right, because we ended with correctly named .patch file, but all we could use for Subject line was the name of the original .patch file (instead of the Subject from metadata commit which introduced this .patch files as some other .patch files get when refreshed with devtool. In the end the issue happens even sooner in GitApplyTree.prepareCommit() where it correctly found the Subject from metadata commit, but then didn't apply it when there weren't any other outlines from patch headers. Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-03meta-selftest: add test of .gitignore in tarballMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-30qemurunner: fix ip fallback detectionKonrad Weihmann
When falling back from detecting ip from /proc/./cmdline the output of runqemu is acutally 'Network configuration: ip=192.168.7.2::192.168.7.1::255.255.255.0' which doesn't match the given regex and leading to run failure, although IP is detectable. Fix regex by inserting an optional 'ip=' prefix to first IP Signed-off-by: Konrad Weihmann <kweihmann@outlook.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-30lib/classextend: Drop unneeded commentRichard Purdie
This was leftover debug which can be removed. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-27qemu: enable virglrenderer and glx options subject to 'opengl' DISTRO_FEATUREAlexander Kanavin
Note that to actually use accelerated GL passthrough, there are two options 1) a suitable frontend need to be also enabled - gtk+ and SDL both seem to work well. Previously I struggled to make SDL work, but now it seems fine. 2) it is also possible to render off-screen with -display egl-headless option, and see the output with a VNC viewer (for which, qemu needs to be started with a VNC server): $ runqemu kvm egl-headless publicvnc Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-27terminal.py: do not stop searching for autoJoe Slater
If a terminal fails to spawn() we should continue looking. gnome-terminal, in particular can be present but not start. Signed-off-by: Joe Slater <joe.slater@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-27multilib/recipes: Use new RecipePostKeyExpansion eventRichard Purdie
There are issues with multilib due to the ordering of events where some functions see the remapped multilib dependencies and some do not. A significant problem is that the multilib class needs to make some changes before key expansion and some afterwards but by using existing event handlers, some code sees things in a partially translated state, leading to bugs. This patch changes things to use a new event handler from bitbake which makes the ordering of the changes explcit. The challenge in doing this is that it breaks some existing anonymous python and dyanmic assignments. In some cases these used to be translated and no longer are, meaning MLPREFIX has to be added. In some cases these are now translated and the MLPREFIX can be removed. This change does now make it very clear when MLPREFIX is required and when it is not, its just the migration path which is harder. The patch changes the small number of cases where fixes are needed. In particular, where a variable like RDEPENDS is conditionally extended (e.g. with an override), MLPREFIX is now required. This patch also reverts: base: Revert 'base.bbclass: considering multilib when setting LICENSE_EXCLUSION' This reverts 6597130256a1609c3e05ec5891aceaf549c37985 as the changes to multilib datastore handling mean its no longer necessary. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-24oeqa/concurrencytest: don't delete build directory for failed testsSteve Sakoman
Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-21testresults.json: add duration of the tests as wellAlexander Kanavin
This is printed by testimage, but isn't actually saved. It's a useful metric for tracking execution times. Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-19lib/oe/recipeutils.py: passthrough of FETCHCMDKonrad Weihmann
let FETCHCMD_* settings be passed to upstream check functions from get_recipe_upgrade_status. It enables using different values for the fetching tools, as otherwise always the defaults are used. E.g. use different timeout or retry values for wget. This is especially useful for remote server that do request-limiting (429) or that are simply unavailable (500, 504) and can speedup upgrade-check for a larger set of recipe significantly Signed-off-by: Konrad Weihmann <kweihmann@outlook.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-18image_types: declare support for wic.zstDiego
Declare images in wic.zst format as supported, as bmaptool now supports zstd: https://github.com/intel/bmap-tools/commit/1b8437d58447d3796dc11fd0f2c62bec5746e5d6 Given the very fast decompression speed of zstd over, for example, gzip, writing images with bmaptool can provide big write speed improvements when decompression speed is the limiting factor (especially with very sparse images). Signed-off-by: Diego Rondini <diego.rondini@kynetics.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-12selftest/imagefeatures: Enable sanity test for IMAGE_GEN_DEBUGFSYeoh Ee Peng
Add new testcase to check IMAGE_GEN_DEBUGFS. Test makes sure that debug filesystem is created accordingly. Test also check for debug symbols for some packages as suggested by Ross Burton. [YOCTO #10906] Signed-off-by: Humberto Ibarra <humberto.ibarra.lopez@intel.com> Signed-off-by: Yeoh Ee Peng <ee.peng.yeoh@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-09lib/oe/package_manager: update default rpm config %_prefer_colorChangqing Li
* %_prefer_color is used by rpm to determine which color's ELF file is preferred to be installed. Here are file colors: 0 is unknown or other 1 is Elf32 2 is Elf64 4 is MIPS64 n32 (this color is added by oe-core's patch) if default value set to 7, all colors are preferred color, always be last-in-wins. For this scenario, when we have 64bits python3 installed first, then install 32bits python3 later, 64bits python3 will be overwrited, and sys.path will point to /usr/lib, not /usr/lib64, this may cause some python3 modules not work. so fixed by remove setting of default value 7, and use default value 2 of rpm * other distro like fedora also use the default %_prefer_color 2 Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-07virgl: skip test on Debian 9Alexander Kanavin
Debian 9 has an older version of mesa, where dri drivers do not link against glapi explicitly, which causes problems when they are loaded by newer mesa-native: pokybuild@debian9-ty-2:~$ ldd -d /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so |grep undefined undefined symbol: _glapi_tls_Dispatch (/usr/lib/x86_64-linux-gnu/dri/swrast_dri.so) undefined symbol: _glapi_tls_Context (/usr/lib/x86_64-linux-gnu/dri/swrast_dri.so) compared to Debian 10: pokybuild@debian10-ty-2:~$ ldd -d /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so|grep undefined pokybuild@debian10-ty-2:~$ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-07testsdkext/devtool: initialize the test component's git repoAlexander Kanavin
Devtool is relying on externalsrc class, which, in order to determine if a rebuild is needed, relies on git to checksum files (if the component tree is a git repo), or sets a flag to always rebuild if the component tree is not a git repo. This is problematic in testsdkext scenario, where the test component is inside a build directory, which itself is inside the poky repo checkout, and listed in .gitignore. What happens is that git walks up the tree and uses the index of the poky repo. This works okay with older versions of git, but git 2.26 complains that we're inside a directory that is ignored, and returns an error. To fix the issue, the git repository is initialized directly in the component directory, just prior to running the tests. Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-05-02oeqa/runtime: Use libdir to run ptest-runnerAnibal Limon
In multilib build configs libs can be installed in /usr/lib{32,64,x32} so use libdir to specify the correct ptest directory along with default /usr/lib. [YOCTO #12604] Signed-off-by: Aníbal Limón <anibal.limon@linaro.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-29image/packagegroup: Remove PACKAGE_GROUP_*, long since deprecatedRichard Purdie
This was deprecated in 2014 so we can safely remove the old code now. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26oeqa/qemurunner: Clean up failure handlingRichard Purdie
If you fail to setup the tap devices, runqemu will error quickly however stdout/stderr are not shown to the user, instead a SystemExit traceback is shown. This could explain some long since unexplained failures on the autobuilder. Rework the error handling so SystemExit isn't used and the standard log failure messages can be shown. The code could likely ultimatley need some restructuring to work effectively. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26targetcontrol: Fix leaking log handlerRichard Purdie
We had a mystery failure on the autobuilder where runqemu appeared to be failing as a logfile directory no longer existed. The key to reproducing was running a runqemu where the image was deleted (as devtool does), then running another runqemu test. E.g.: 'oe-selftest -r devtool.DevtoolExtractTests.test_devtool_deploy_target wic.Wic2.test_qemu_efi' This then tries to write to the logfile from the first test, the image directory was deleted and we get strange failures. The fix is to remove the logging handler when qemu is stopped. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26oeqa: wic: Add more tests for include_pathRicardo Ribalda Delgado
Make sure permissions are respected. Add new test for orig/destination option. Cc: Paul Barker <pbarker@konsulko.com> Signed-off-by: Ricardo Ribalda Delgado <ricardo@ribalda.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26oeqa: wic: Add tests for permissions and change-directoryRicardo Ribalda Delgado
Make sure that the permissions and username are respected when using all the rootfs modifiers. Add tests for change-directory command Cc: Paul Barker <pbarker@konsulko.com> Signed-off-by: Ricardo Ribalda Delgado <ricardo@ribalda.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26oeqa/selftest: Add test for conflicting sysroot providerRichard Purdie
sysroot-test depends on virtual/sysroot-test which we build for one machine, switch machine, switch provider of virtual/sysroot-test and check that the sysroot is correctly cleaned up. The files in the two providers overlap so can cause errors if the sysroot code doesn't function correctly. Yes, sysroot-test should be machine specific really to avoid this, however the sysroot cleanup should also work. This adds a test for bug: [YOCTO #13702] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-26selftest/package: Add test to ensure ownership is preservedDaisuke Yamane
Yocto Bug: https://bugzilla.yoctoproject.org/show_bug.cgi?id=13806 Add test_preserve_ownership to selftest/package. This test creates a file, a directory and a symbolic link and changes ownership, then compares with them installed in rootfs to ensure ownership is preserved. [Test without a commit 'bitbake: lib/bb/utils.py: Preserve ownership of symlink'] | 2020-03-14 10:01:14,519 - oe-selftest - INFO - test_preserve_ownership (package.PackageTests) | 2020-03-14 10:56:44,612 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/file | 2020-03-14 10:56:44,770 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/dir | 2020-03-14 10:56:44,822 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/symlink | 2020-03-14 10:56:44,879 - oe-selftest - ERROR - Incrrect ownership /etc/selftest-chown/symlink [root:root] | 2020-03-14 10:56:45,884 - oe-selftest - INFO - ... FAIL [Test with a commit 'bitbake: lib/bb/utils.py: Preserve ownership of symlink'] | 2020-03-14 10:58:49,599 - oe-selftest - INFO - test_preserve_ownership (package.PackageTests) | 2020-03-14 11:51:39,947 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/file | 2020-03-14 11:51:40,013 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/dir | 2020-03-14 11:51:40,063 - oe-selftest - INFO - Check ownership of /etc/selftest-chown/symlink | 2020-03-14 11:51:41,118 - oe-selftest - INFO - ... ok Signed-off-by: Daisuke Yamane <daisuke.yamane@cybertrust.co.jp> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-25oeqa/runtime/weston: Enhance weston testsYeoh Ee Peng
Existing weston test available make sure that a process for weston-desktop-shell exist when image boot up. Enhance weston tests by: - execute weston-info to make sure weston interface(s) are initialized - execute weston and make sure it can initialize a new wayland compositor (retry checking for wayland processes up to 5 times) - enable weston logging for debugging when fail to initialize wayland compositor [YOCTO# 10690] Signed-off-by: Yeoh Ee Peng <ee.peng.yeoh@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-24testimage: enable ovmf supportKonrad Weihmann
Add support for running wic images with EFI as testimage. Introduces a variable called QEMU_USE_OVMF for configuration. Signed-off-by: Konrad Weihmann <kweihmann@outlook.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-24parselogs.py: ignore pulseaudio startup warning messagesChangqing Li
If set default syslog to rsyslog, we can see below messages in user.log, [pulseaudio] authkey.c: Failed to open cookie file [pulseaudio] authkey.c: Failed to load authentication key They are only warnings when cookie file is not found. And PulseAudio will create it if it doesn't exist. refer: https://wiki.archlinux.org/index.php/PulseAudio/Configuration https://lists.freedesktop.org/archives/pulseaudio-discuss/2014-December/022719.html Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-07parselogs.py: update network interface related messagesChangqing Li
along with systemd upgrade, error message related change network interface have changed, update it. Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-02prservice.py: fix do_package with newer Python in Ubuntu 20.04Martin Jansa
* with Ubuntu 20.04 which is using python 3.8 I'm seeing a lot of errors like: ERROR: libxml2-2.9.10-r0 do_package: Can NOT get PRAUTO, exception No module named '_sysconfigdata' not sure what caused this from python 3.8, but this seems to work * PRserv is enabled with: PRSERV_HOST = "localhost:0" Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/package_manager: don't try to rm /var/lib/opkgJan Luebbe
As opkglibdir starts with a /, os.path.join will ignore self.target_rootfs, leading to an attempt to remove /var/lib/opkg. This only fails if it exists on the host, explaining why this remained undiscovered for long. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/package_manager: avoid installing provided packages via aptJan Luebbe
If there already is a package providing (and conflicting against) packages what should be installed, apt will try remove the conflicting package (target-sdk-provides-dummy) and any that depend on it (like apt and dpkg). This usually fails because of the protection of essential packages. In that case, no -dev/-dbg packages are installed to the SDK. Avoid this problem by checking which packages are already provided and removing them from the list to be installed. Also sort the list to make it easier to read when debugging. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/package_manager: collect provided package names when using debsJan Luebbe
This is needed for a later change to avoid installing packages which are already provided by an installed package. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/package_manager: fix handling of last packageJan Luebbe
In commit 7d214b34e11dc57316ed5c1c7747c4601286f6d2, only the code in the for loop was modified to store the pkgarch value. The code used if there was no empty line at the end was not modified. Instead of fixing the duplicated code, remove it and just make sure that a final empty line is processed. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/package_manager: make sure to not remove packages in apt installJan Luebbe
apt install can decide to remove already installed packages if there are conflicts. Avoid this by explicitly specifying --no-remove. This will then cause a "E: Packages need to be removed but remove is disabled." message. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-04-01lib/oe/utils.py: add get_host_compiler_version()Tim Orling
Add helper function to get the host compiler and version. Do not assume compiler is gcc. NOTE: cannot set env to d.getVar("PATH") as that does not contain the session PATH which was set by environment-setup-... which breaks the install-buildtools use-case Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-30prservice.py: Use "with" to control file handle lifetimePeter Kjellerstedt
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>