| Summary: | Unable to "devtool build <package>" in /build directory | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Yocto Project Subprojects] eSDK | Reporter: | WeiHeng Cheng <weiheng.cheng> | ||||
| Component: | eSDK | Assignee: | Unassigned <unassigned> | ||||
| Status: | IN PROGRESS REVIEW --- | QA Contact: | Francisco Pedraza <francisco.j.pedraza.gonzalez> | ||||
| Severity: | normal | ||||||
| Priority: | Medium | CC: | randy.macleod, sgw, weiheng.cheng | ||||
| Version: | unspecified | ||||||
| Target Milestone: | 5.99 | ||||||
| Hardware: | x86 | ||||||
| OS: | Multiple | ||||||
| Whiteboard: | |||||||
| OS type for building Yocto: | --- | Type of Regression: | --- | ||||
| Verified: | Documentation change: | Don't know | |||||
| Attachments: |
|
||||||
|
Description
WeiHeng Cheng
2023-02-02 02:50:13 UTC
This is a bug but the obvious work-around is to use a different directory name. (In reply to comment #1) > This is a bug but the obvious work-around is to use a different directory > name. Yes, I'm aware of the workaround. However, there are systems that use /build directory. FYI, if the <package> uses a directory name same as any directory that exists in /build/username/yocto-esdk/nodistro_sdk/tmp/work/riscv64-oe-linux/<package>/<package-revision>/package/usr/src/debug/, the "devtool build <package>" will encounter the same error. Hence, I wonder if the line: cmd = "mv %s%s%s/* %s%s" % (dvar, debugsrcdir, sdir, dvar,debugsrcdir) is replaced with: cmd = "cp -r %s%s%s/* %s%s && rm -rf %s%s%s/*" % (dvar, debugsrcdir, sdir, dvar, debugsrcdir, dvar, debugsrcdir, sdir) will it work without any implication? If this fix can work, I can submit a patch for this. Thanks! So I tried to reproduce this using a /build/<username>/sdk NOTE: python3-numpy: compiling from external source tree /build/swold/sdk/workspace/sources/python3-numpy devtool modify / devool build worked correctly. The workdir: /build/swold/sdk/tmp/work/core2-64-poky-linux/python3-numpy/1.24.1-r0 I am using the current master branch, it did not reproduce, I guess I need more details. (In reply to comment #3) > So I tried to reproduce this using a /build/<username>/sdk > > NOTE: python3-numpy: compiling from external source tree > /build/swold/sdk/workspace/sources/python3-numpy > > devtool modify / devool build worked correctly. > > The workdir: > /build/swold/sdk/tmp/work/core2-64-poky-linux/python3-numpy/1.24.1-r0 > > I am using the current master branch, it did not reproduce, I guess I need > more details. Hi Saul, FYI previously I replicated the error using Kirkstone branch for openembedded-core. I tried to replicate the error using master branch for openembedded-core but end up with no error, as what you found out. So, I think you can replicate it if you use Kirkstone branch for openembedded-core. If possible, try to use bitbake version 2.0 and Kirkstone branch for all layers. Thanks! Ok, I missed that it was kirkstone specific, you mentioned it was a line in multiple releases including master. Please try testing that attached patch which I think helps with this specific case, yes it's a bit of a corner case due to the /build directory as Randy pointed out. This moves the internal /usr/src/debug/build to /usr/src/debug/build.build and then does the other move. I think you might have actually found an issue with master also, which I need to review more carefully. Created attachment 4931 [details]
Patch for testing /build issue
Please test patch (In reply to comment #5) > Ok, I missed that it was kirkstone specific, you mentioned it was a line in > multiple releases including master. > > Please try testing that attached patch which I think helps with this > specific case, yes it's a bit of a corner case due to the /build directory > as Randy pointed out. > > This moves the internal /usr/src/debug/build to /usr/src/debug/build.build > and then does the other move. > > I think you might have actually found an issue with master also, which I > need to review more carefully. Hi Saul, The patch works fine, no issue with the "devtool build <package>" command. I also tested the image with edited recipe to make sure everything works fine, sorry for the delay. Regarding the issue with master that you've mentioned, do you mean that the "dvar + debugsrcdir + sdir" path is missing? Thanks! Patch sent to list Build move to 5.0 -- ../Randy Bulk move of 5.0 medium importance issues to 5.99. Move to 5.1 if you want to actively work on an issue. Move to 5.99 since no one is actively working on this issue. Move to 5.x if you start on a task, please. bulk change to add Saul's non-WR address. Bulk change: Remove Saul's old WR address. |