summaryrefslogtreecommitdiffstats
path: root/scripts
Commit message (Collapse)AuthorAgeFilesLines
...
* scripts/bblock: add a script to lock/unlock recipesJulien Stephan2023-10-091-0/+184
| | | | | | | | | | | | | | | | | | | | | | | | | bblock script allows to lock/unlock recipes to latest task signatures. The idea is to prevent some recipes to be rebuilt during development. For example when working on rust recipe, one may not want rust-native to be rebuilt. This tool can be used, with proper environment set up, using the following command: bblock <recipe_name> See help for more details if a <recipe_name>'s task signature change, this task will not be built again and sstate cache will be used. [YOCTO #13425] (From OE-Core rev: 2d9ab0cfd7f3cacc347954676f1323342a6b286f) Signed-off-by: Julien Stephan <jstephan@baylibre.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* devtool/upgrade: check all git config locationsMarcus Flyckt2023-10-081-1/+1
| | | | | | | | | | | | | | | | | Fixes [YOCTO #15222] In some situations its more practical to keep git configuration at `/etc/gitconfig` instead of `$HOME/.gitconfig` (e.g., when mounting git configuration into a docker container). This change makes `devtool upgrade` consider any available git configuration instead of only checking `--global`. (From OE-Core rev: 30a9f7de45050c8bac49d4b37419cc2e067a75fa) Signed-off-by: Marcus Flyckt <marcus.flyckt@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool/create_buildsys_python: use importlib instead of impChris Laplante2023-10-061-3/+2
| | | | | | | | | | | 'imp' was deprecated in Python 3.4 and removed in 3.12. The piece of importlib we use has been around since 3.3. (From OE-Core rev: 457f0dad87b4e45a53865b5ad2c150215bd74019) Signed-off-by: Chris Laplante <chris.laplante@agilent.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/oe-setup-layers: Update how to determine if directory is git repoJermain Horsman2023-10-061-5/+5
| | | | | | | | | | | | | | | | | | | | | Previously _is_repo_git_repo() would return a result containing b'true\n' or b'false\n' if 'git rev-parse' ran successfully, instead of True of False. While this can be solved using e.g. result.strip().decode("utf-8") == "true", there are some other cases to consider. First, .git can be a file and not a directory when using a worktree. Second, an emtpy .git directory in 'repodir' for which some parent of 'repodir' is an actual git repo will still return True in this case. To account for these cases as well, use 'git rev-parse --show-toplevel' and compare the result against 'repodir' instead of using 'git rev-parse --is-inside-git-dir'. (From OE-Core rev: 0830f53900dd7fd669a7d6492325559ad3225302) Signed-off-by: Jermain Horsman <jermain.horsman@nedap.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* wic: Add console parameters to qemux86 canned-wksRichard Purdie2023-10-041-1/+1
| | | | | | | | | | | Currently our wic test images boot up without kernel output on the consoles which means we have no way to debug if anything goes wrong. Add the console parameters runqemu would have added if the kernel wasn't built into an image to improve our chances of debugging. (From OE-Core rev: 63ea1efdaaf1173ef4f2f69b5a3403afef4b556a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scritps/runqemu: Ensure we only have two serial portsRichard Purdie2023-10-041-4/+13
| | | | | | | | | | | | | | | | | | | I have a theory that some of the console boot issues we're seeing are due to starting images with three serial ports yet only starting gettys on two of them. This means that occasionally, depending on the port numbering we may not get a login prompt on the console we expect it on. To fix this, change the runqemu code so that if serial ports are passed in on the commandline (as is the case in automated testing), we don't add any other GUI serial consoles. We do need to make sure we do have at least two serial ports since we don't want getty timeout warnings. (From OE-Core rev: 1b0348535dce3b776efbcf26406b94730a51eb85) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* wic: bootimg-partition: Fix file name in debug messageDaniel Semkowicz2023-10-011-1/+1
| | | | | | | | | | Debug message about using custom configuration file includes file name with incorrect extension. Correct file name to "extlinux.conf". (From OE-Core rev: dd63e1520454b2d53a48b72eaae126059af9809b) Signed-off-by: Daniel Semkowicz <dse@thaumatec.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool/devtool: Ensure server knows about changed filesRichard Purdie2023-09-185-1/+6
| | | | | | | | | Bitbake has changed to require notification when metadata changes in the middle of tinfoil sessions. Add the required function calls at the places metadata is changed. (From OE-Core rev: e5574163ab49a8f51b2b34fd37acfd1cad9b7595) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* devtool/build_sdk: Drop unused importsRichard Purdie2023-09-181-1/+1
| | | | | | | | Drop some unused imports. (From OE-Core rev: 432446ef402ff42fe0c90172b77376fa5981524a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* update_mandb: deb fails due to missing man cacheEilís 'pidge' Ní Fhlannagáin2023-09-171-0/+2
| | | | | | | | | | | | | This only occurs in debian package builds when populating the sdk and is a work around that seems to work. Eventually we should look at why this is failing (I have ideas, it's somewhere in lib/oe/package_management/deb/sdk.py), but for now, do this so we can fix the core issue with nativesdk-intercepts. (From OE-Core rev: a411123a95114233c5efd762dbcc8eb513030aab) Signed-off-by: Eilís 'pidge' Ní Fhlannagáin <pidge@baylibre.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pybootchartgui: also match do_compile and do_configure subtasksJose Quaresma2023-09-091-0/+9
| | | | | | | | | | | | | | | | | | | | | | This will match other deviation subtask of the same main task, a couple of them can be found on oe-core layer: do_compile_kernelmodules do_compile_ptest cmake_do_configure setuptools3_do_configure cargo_common_do_configure python_pyo3_do_configure python_setuptools3_rust_do_configure This task will be also painted with the same color of the main task but using alpha blending. (From OE-Core rev: f10582b1c9a5639b48a4663453d201652facb179) Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* build-sysroots: target or native sysroot population need to be selected ↵Alexander Kanavin2023-09-091-1/+2
| | | | | | | | | | | | | | | | | explicitly Running them in parallel is prone to races as postinsts from target sysroots rely on executables from native sysroots which may or may not be fully prepared yet. This was observed for example here: https://autobuilder.yoctoproject.org/typhoon/#/builders/146/builds/468/steps/12/logs/stdio https://autobuilder.yoctoproject.org/typhoon/#/builders/147/builds/467/steps/12/logs/stdio (From OE-Core rev: 38d7a2e45b883cf999a86af05bcc0eaa875bb47c) 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>
* runqemu: check permissions of available render nodes as well as their presenceAlexander Kanavin2023-09-091-2/+12
| | | | | | | | | | | | | | | | | | | | | qemu itself is not helpful when render nodes exist, but can't be opened: qemu-system-x86_64: egl: render node init failed To fix this, users likely need to * modprobe vgem (presence when physical graphic card is absent or has a driver without support for render nodes, such as many older cards found in server machines) * add their user to "render" group to write to /dev/dri/renderD* (permissions) With this change runqemu should print hints for the above as appropriate from probing the nodes. (From OE-Core rev: acd85925cb197b7a31a25b60e8de762e2c3697ef) 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>
* nativesdk-intercept: Fix bad intercept chgrp/chown logicEilís 'pidge' Ní Fhlannagáin2023-09-082-2/+8
| | | | | | | | | | | | | | | | | | | | | | | Running either of these ends up corrupting the os.execv args. If we run: ./scripts/nativesdk-intercept/chown -R foo:foo bar The loop here ends up missing the conversion of foo:foo to root:root because it sees sys.argv[0] and assumes that it's the user:group argument and that we should convert that. We end up a os.execv(path, args) that have the following args: ['root:root', '-R', 'foo:foo', 'bar'] As os.execv ignores args[0], we can just populate it with sys.argv[0] and then loop through sys.argv[1:]. As both chgrp and chown would have either flags and USER[:GROUP] next, this fixes the issue. (From OE-Core rev: 2a75f647ec7696d353f4b09099d777ba53f34d36) Signed-off-by: Eilís 'pidge' Ní Fhlannagáin <pidge@baylibre.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/oe-find-native-sysroot: use bitbake-getvarRoss Burton2023-09-071-13/+2
| | | | | | | | | Instead of bitbake and grep, just use bitbake-getvar. (From OE-Core rev: b5011a2fc248d88b5491cf6af1fc15e5974f6e45) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oe-depends-dot: improve '-w' behaviorChen Qi2023-09-021-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | The '-w' option is not giving very helpful information. For example, if we add 'spice' to IMAGE_INSTALL, bitbake -g core-image-minimal, and then run `oe-depends-dot -k nspr -w task-depends.dot', the result is: $ oe-depends-dot -k nspr -w task-depends.dot Because: core-image-minimal nss core-image-minimal -> nss -> nspr The result is not showing the full dependency chain which brings in nspr. With this patch, the result is: $ oe-depends-dot -k nspr -w task-depends.dot Because: core-image-minimal nss libcacard spice core-image-minimal -> spice -> libcacard -> nss -> nspr This patch also fixes a typo in help message: recipe-depends.dot -> task-depends.dot. (From OE-Core rev: 222302810c472c8eb2efceaa757a253dcac5618f) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* wic: Add gpt-hybrid partition layoutJoshua Watt2023-09-023-17/+69
| | | | | | | | | | | | | | | | | | | | | | | Add support for formatting a disk with a hybrid MBR & GPT partition scheme. In this scheme, the primary partitioning method is GPT, but a valid MBR header is also written than can point to a subset of the GPT partitions on the disk (any partitions marked with the `--mbr` flag will be included in this MBR). The primary purpose of this method is to allow for SoCs that can only find a bootloader in an MBR partition to use GPT once the bootloader is running. As an example, older versions of the Raspberry Pi firmware can only parse MBR partitions to find a kernel (or other bootloader like u-boot), but once those have booted GPT partitions can be used. In addition to the partitions annotated with the `--mbr`, a "protective" GPT partition of type 0xEE is added, as the existence of such a partition is the indication to tooling that this a hybrid MBR and that the GPT partition table should be parsed instead. (From OE-Core rev: e50e4c2a5ada6947b3503ca4d8e9c30d359e8a5d) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipes/classes/scripts: Drop SRCPV usage in OE-CoreRichard Purdie2023-08-242-2/+2
| | | | | | | | Now that SRCPV isn't needed we can simplify things in a few places... (From OE-Core rev: 843f82a246a535c353e08072f252d1dc78217872) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oe-buildenv-internal: update required Python versionTrevor Gamblin2023-08-211-4/+4
| | | | | | | | | | | The system requirements in the current version of the reference manual state that Python 3.8.0 is the minimum version, but oe-buildenv-internal still only checks for 3.5.0 or newer. Update the script to match. (From OE-Core rev: 3e655a07f2de64dbf39189c3ece56803f6bc334e) Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* wic: fix wrong attempt to create file system in upartitioned regionsMarkus Niebel2023-08-211-1/+1
| | | | | | | | | | | | | | | | The kickstart parser defaults fstype to "vfat". This leads to an attempt to create an empty file system even for regions configured with "--no-table" if used without fstype when no --sourceparams given. The fix tests for fstype "none" or no_table in Partition prepare method. This will omit the file system creation an the potential error for small region with --no-table option. (From OE-Core rev: db771a4cd36bf291a8b68edfd905e03243f2c8b3) Signed-off-by: Markus Niebel <Markus.Niebel@ew.tq-group.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* resulttool/report: Avoid divide by zeroRichard Purdie2023-08-151-1/+4
| | | | | | | | Avoid a divide by zero traceback if unfortunate test counts are encountered. (From OE-Core rev: c5aeea53dfacb53dedb8445cb3523dc3a8cb6dca) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/create-pull-request: update URLs to git repositoriesMichael Opdenacker2023-08-141-5/+2
| | | | | | | | | | Also remove the git.pokylinux.org URL, no longer used. (From OE-Core rev: 47b88d143c2fc61ce0e03b7eb3a9dbcffadbf5b1) Signed-off-by: Michael Opdenacker <michael.opdenacker@bootlin.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* wic: bootimg-efi: Stop hardcoding VMA offsetsAlexandre Belloni2023-08-091-14/+49
| | | | | | | | | | | | | | | | Section VMA's are currently hardcoded. This doesn't work anymore starting with systemd-boot v254. Follow the actually solution to this which is documented here: https://wiki.archlinux.org/title/Unified_kernel_image#Manually This is also used by dracut. Later on, we may want to switch to ukify instead but this is not ready yet. (From OE-Core rev: 3abf99a6c6bde2fb8770f54dba609b35f6c6ee5a) Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* qemuboot/runqemu: Fix 6.2 and later kernel network device namingRichard Purdie2023-08-091-1/+1
| | | | | | | | | | | | | With kernel 6.2 and later network devices are renamed by systemd. This does not match with the current network device naming assumed in our configuration. We may or may not change that naming but for now, pass the right kernel commandline so things work as expected with newer kernels and removing a blocker on upgrading to the 6.4 kernel by default. (From OE-Core rev: 9e9c33d51e401fe2b4a632db74ccb3449e4b23ee) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/resulttool: define custom string for "not found" test resultsAlexis Lothoré2023-08-041-0/+1
| | | | | | | | | | | | | | | | | | | Whenever a test result is present in base test result but absent from target test results, we have an entry in regression report looking like the following one: ptestresult.apr.testfile: PASSED -> None The "None" status may be a bit confusing, so replace it with a custom string which really states what "None" means in this context: ptestresult.apr.testfile: PASSED -> No matching test result (From OE-Core rev: b5f6da6e13f3484f51dfa07f6b3500aea7a21825) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/resulttool: allow to replace test raw status with custom stringAlexis Lothoré2023-08-041-1/+7
| | | | | | | | | | | | | Add a STATUS_STRINGS dictionnary matching raw statuses to custom strings. Whenever a regression must be reported, raw status is searched in the custom statuses dict (key search is case insensitive). If no custom string is found, raw status is kept and used in regression report (From OE-Core rev: 9d22bfc9d0c4092dba1af0ee11a4c51b7b270786) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/lib/scriptutils.py: add recipe_qa artifacts to exclusion list in ↵Alexander Kanavin2023-08-041-1/+1
| | | | | | | | | | | | | | | filter_src_subdirs() With newly added recipe_qa task, the function needs to filter out its output as well. The issue wouldn't appear in selftest because it's triggered by buildhistory and selftest disables that. (From OE-Core rev: da1284c990957827ee89685921c53b64490a32b2) 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>
* devtool/upgrade: raise an error if extracting source produces more than one ↵Alexander Kanavin2023-08-041-0/+2
| | | | | | | | | | | | | | | | | | | directory This can happen if running unpack task produces unrelated files and directories (e.g. if recipe_qa or other tasks run); in this case it's better to stop, rather than allow devtool to continue and error out much later with a message that has nothing to do with where the problem originated. The idea here was to handle tarballs that don't contain a top level directory and thus the source tree is one level up; this basically never happens, and if it does we should find a less brittle way to handle such tarballs. (From OE-Core rev: b25e922b271794906b22450c7e6cc18fcab51ff8) 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>
* devtool: do not run recipe_qa task when extracting sourceAlexander Kanavin2023-07-301-0/+2
| | | | | | | | | | | | | | | | | | | | The immediate reason is that the task is sstate enabled, and due to the way devtool sets up source extraction this causes bogus values to appear in tmp/sstate-control/index-* files. Also, recipe_qa may contain hard failures in the future, and it would be counterproductive for the failures to prevent devtool workflows (which may perhaps be about fixing the failure). An alternative would have been to not insert recipe_qa task before fetch task, but that would greatly delay the checks in larger bitbake builds, and it's better to run them as early as possible. (From OE-Core rev: 6f9db3f8de3dca9b0c87382561c70857d5b39e0f) 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>
* scripts/resulttool: add mention about new detected testsAlexis Lothoré2023-07-251-2/+14
| | | | | | | | | | | | | | | | Some regression reports show a lot of "PASSED->None" transitions. When such big lot of identical transitions are observed, it could be that tests are now failing, but it could also be that some tests has been renamed. To detect such case, add a log in regression report to report the number of new tests (i.e: tests that are present in target results but not in base result). This new log also allows to know about newly added tests bases (From OE-Core rev: 01b5cefd07e01c7407bc663842b8a8d502358a6d) Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* resulttool/resultutils: allow index generation despite corrupt jsonMichael Halstead2023-07-191-1/+5
| | | | | | | | | | | non-release indexes will continue to generate when test output is corrupted. (From OE-Core rev: 1a9157684a6bff8406c9bb470cb2e16ee006bbe9) Signed-off-by: Michael Halstead <mhalstead@linuxfoundation.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pybootchartgui: fix width max usage in draw_label_in_boxJose Quaresma2023-07-141-1/+1
| | | | | | | | | | | | | The function draw_label_in_box chooses the correct side based on the maximum width length argument 'maxx'. Currently the labels are always drawn on the left side and this is because we are inadvertently passing the 'maxx' argument wrong. (From OE-Core rev: b1cea47c52899a85428e0bddf82ba6a07689673b) Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pybootchartgui: fix overlapping argument in render_processes_chartJose Quaresma2023-07-141-2/+2
| | | | | | | | | | | There is another variable named 'w' on the function which is redefined. The full width is needed in the function so rename it as this must be unique. (From OE-Core rev: 81389ccdf22d3ea845ae8d894a0e4e0cdf589f2a) Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pybootchartgui: concatenate the elapsed time with the processJose Quaresma2023-07-141-3/+2
| | | | | | | | | | | | The function draw_label_in_box have logic to chose the rigth side to call the draw_text, so use it instaed of forcing the cordinates of the right side. (From OE-Core rev: b369e9bb0136fecc65f49e0965e5506aa50f489e) Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pybootchartgui: calcule elapsed_time when starting the loopJose Quaresma2023-07-141-3/+3
| | | | | | | | | | | Instaed of calculate the elapsed time over the loop when needed do it on the loop startup. (From OE-Core rev: 63a19626f10873cd7a4aabee7c9777fdede83bcb) Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* scripts/oe-setup-builddir: copy conf-notes.txt to build dirStéphane Veyret2023-07-101-5/+9
| | | | | | | | | | | | | | | Since commit 569d4cd325, if one is using a custom template directory containing a conf-notes.txt, this file is only displayed when creating a new environment. When entering an already existing environment, only the default poky conf-notes.txt is displayed. This patch copies the conf-notes.txt to display to the build directory, so that the good file is shown, even when templateconf.cfg is not used. (From OE-Core rev: 845e8292f218d740ee653fa68bc3110aec1af3c5) Signed-off-by: Stéphane Veyret <sveyret@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool: create: npm: Add support to handle peer dependenciesBELOUARGA Mohamed2023-06-291-0/+20
| | | | | | | | | | | | | | | | | NPM changed its manner to handle peer dependencies over its versions. Before NPM 3: NPM installs automatically peer dependencies between NPM 3 and 7: NPM shows a warning about peer dependencies After NPM 3: NPM reworked its manner how to handle peer dependencies The shrinkwrap doesn't have the parameters of the peer dependencies, so we cannot fetch them. in the same time peer dependencies are not direct dependencies, they should be installed as run time dependencies. (From OE-Core rev: f36021a749974ef3d4a6abe4d5429544a815071a) Signed-off-by: BELOUARGA Mohamed <m.belouarga@technologyandstrategy.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool: create: npm: Add support for the new format of the shrinkwrap fileBELOUARGA Mohamed2023-06-291-5/+4
| | | | | | | | | | | The shrinkwrap file changed its format, but npm does not version this file. So we can use it properly. The actual changes make the script check if the npm package has dependencies in the actual shrinkwrap format. (From OE-Core rev: 488d17c2af0c927ec66f0eee124bf6fc5b7f7c95) Signed-off-by: BELOUARGA Mohamed <m.belouarga@technologyandstrategy.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool: create: npm: Remove duplicate function to not have future conflictsBELOUARGA Mohamed2023-06-291-11/+3
| | | | | | | | | | | | | | Npm packages do not have yocto friendly names. fore instance we can have names like "@example/npmPackage" npm fetcher has a function that convert these names to yocto friendly names. But in recipe tool we have an other function (duplicate). (From OE-Core rev: 18e5438de5389b58c8b6a548d4474128d510a28d) Signed-off-by: BELOUARGA Mohamed <m.belouarga@technologyandstrategy.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipetool: Fix inherit in created -native* recipesYoann Congal2023-06-281-0/+4
| | | | | | | | | | native and nativesdk classes are special and must be inherited last : put them at the end of the gathered classes to inherit. (From OE-Core rev: a6614fd800cbe791264aeb102d379ba79bd145c2) Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu: drop uid parameter for ifdownAdrian Freihofer2023-06-281-1/+1
| | | | | | (From OE-Core rev: 5f6f8f399b146615eeea8c2590f1588a8c150d13) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-ifdown: catch up with ifupAdrian Freihofer2023-06-281-6/+15
| | | | | | | | | | | | | - Drop the native-sysroot-basedir parameter still allow it to keep backward compatibility write a warning to stderr - Add a space after ! in the if as suggested by shellcheck - Support the new OE_TAP_NAME variable as well (From OE-Core rev: be72e5e32da5a251db14b42d3e9c0951178e216d) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu: Fix automated call to runqemu-ifupAlejandro Hernandez Samaniego2023-06-282-2/+2
| | | | | | | | | | | | | | | | | | | When runqemu tries to call runqemu-ifup to create tap devices, it checks the output of runqemu-ifup to get the newly created tap device. The behavior of runqemu-ifup was recently modified along with its output, it no longer expects the uid parameter to be passed and it prints out a warning if it was, since this warning was now part of the output runqemu tries to parse it and convert it to an int() which proved impossible. Pass the correct arguments to the runqemu-ifup call and echo the warning to stderr instead to make sure its not being parsed and used by runqemu in any case. (From OE-Core rev: ce3a2f4cec28290c8e530989f17243f1ada4e3bd) Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandro@enedino.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu: Stop using warn() since its been deprecatedAlejandro Hernandez Samaniego2023-06-281-2/+2
| | | | | | | | | logger.warn() has been deprecated, logger.warning() should be used instead. (From OE-Core rev: 9263497880b3154d65ed713498749f906534a055) Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandro@enedino.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu: configurable tap namesAdrian Freihofer2023-06-241-2/+6
| | | | | | | | | | Support the new environment variable OE_TAP_NAME. (From OE-Core rev: 6795dddb4074274279b7ff7b9639d15786f06a40) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-gen-tapdevs: remove only our tapsAdrian Freihofer2023-06-241-1/+1
| | | | | | | | | | Ignore itnerfaces with other names than what the runqemu scripts created. (From OE-Core rev: e99ec79a423d09b9308e3d42f0832ee583b1456d) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-gen-tapdevs: configurable tap namesAdrian Freihofer2023-06-241-3/+7
| | | | | | | | | | | Feature: Hard-coding the interface names to tap* is not always a good idea. (From OE-Core rev: 739f20481d14a66b23d6195c3837f83d7370434a) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-gen-tapdevs: remove uid parameterAdrian Freihofer2023-06-241-15/+18
| | | | | | | | | | | | The uid parameter is no longer needed since ip tuntap is used internally. Remove it. Backward compatibility to 3 or 4 parameters is still supported. (From OE-Core rev: a11c87b0a13f81beea8a9f33ef8379c9d2593e59) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-gen-tapdevs: remove staging dir parameterAdrian Freihofer2023-06-241-5/+7
| | | | | | | | | | | | The parameter staging_bindir_native is no longer used. Remove it. For now the script is backward compatible. With 4 parameters it logs an error message but still works. (From OE-Core rev: c47322297fcd0408c5e290e74eee4344754e03e4) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu-ifup: remove only our tapsAdrian Freihofer2023-06-241-1/+1
| | | | | | | | | | | | If there are other tap interfaces than the interfaces created by the runqemu-* scripts, these interfaces are not ignored. This is now fixed by filtering the interfaces for a specific prefix in the interface name. (From OE-Core rev: f65fb5fce45d13c2881acd8295d417635449c52d) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>