| Summary: | go-vendor.bbclass: avoid QA errors with absolute paths | ||
|---|---|---|---|
| Product: | [Build System, Metadata & Runtime] OE-Core | Reporter: | Robert Berger <pokylinux> |
| Component: | core | Assignee: | Thomas Vandenabeele <thomas> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | minor | ||
| Priority: | Medium | CC: | meta.mr.watcher, meta.watcher, randy.macleod, richard.purdie, thomas, yoann.congal |
| Version: | 5.3 | ||
| Target Milestone: | 5.2 | ||
| Hardware: | All | ||
| OS: | Multiple | ||
| Whiteboard: | |||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | Don't know | |
|
Description
Robert Berger
2024-12-06 17:26:46 UTC
Example which fails without my patch: https://gitlab.com/meta-layers/meta-yocto-training/-/tree/master/recipes-training/golang-helloworld?ref_type=heads Error: ERROR: github.com-robertberger-golangexample-1.0+git-r0 do_populate_sysroot: sstate found an absolute path symlink /workdir/build/multi-v7-ml-debug-training-master/tmp/work/armv7at2hf-neon-resy-linux-gnueabi/github.com-robertberger-golangexample/1.0+git/sysroot-destdir/usr/lib/go/src/github.com/robertberger/golangexample/vendor pointing at /workdir/build/multi-v7-ml-debug-training-master/tmp/work/armv7at2hf-neon-resy-linux-gnueabi/github.com-robertberger-golangexample/1.0+git/git/src/import/vendor. Please replace this with a relative link. Ricahard says that it's better to avoid creating the incorrect symlinks rather than creating them and then fixing them afterwards. https://bugzilla.yoctoproject.org/show_bug.cgi?id=15683#c3 should explain it, plus my test case. Please note, that except for the selftests I seem to be the only one using this class in my example: $ grep --include \*.bb --include \*.inc --include \*.bbclass -r go-vendor . ./meta-yocto-training/recipes-training/golang-helloworld/github.com-robertberger-golangexample_git.bb:inherit go-vendor Besides, I am not sure how the selftest does not show this issue. Maybe the test case needs to be improved? "It's better to avoid creating the incorrect symlinks rather than creating them and then fixing them afterwards" Yes sure. The question is who creates them? ;) I've sent a patch to the list which changes go-vendor to create relative symlinks in the first place. Just for completeness, here is the patch: https://git.yoctoproject.org/poky/commit/meta/classes/go-vendor.bbclass?id=c323d56244644964d68e012e688b3339492e50c4 Is this patch planned to be applied to the scarthgap branch as well? I ran into the same issue after creating a basic Go recipe using 'recipetool create'. I was about to file a bug for this problem, but I noticed that an existing report already addresses it and that it has been fixed upstream. Hi Thomas, If you think this makes sense as a backport, will you please test it and send an email: https://docs.yoctoproject.org/contributor-guide/submit-changes.html#submitting-changes-to-stable-release-branches If so, please change the status of this defect. Thanks. CC-ing Yoann who maintains the stable branches. Hello Randy, I have submitted the patch after test and validation: https://patchwork.yoctoproject.org/project/oe-core/patch/20260214160806.3043158-1-thomas@bootzero.one/ |