Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH v2 0/5] llvm/clang: fix some syntax issues in llvm-project-source
@ 2026-06-23 12:08 João Marcos Costa
  2026-06-23 12:08 ` [PATCH v2 1/5] llvm-project-source.inc: fix string replacements in do_preconfigure João Marcos Costa
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: João Marcos Costa @ 2026-06-23 12:08 UTC (permalink / raw)
  To: openembedded-core; +Cc: thomas.petazzoni, raj.khem, João Marcos Costa

Hello,

I faced some strange build issues when switching from one distro to another
(i.e. DISTRO="poky" to DISTRO="foobar"), even after adding "foobar"
("foobar:foobar" actually) to CLANG_EXTRA_OE_DISTRO. I started investigating
what was wrong, and I believe the order of pathes in this series reflects pretty
well what specific issue I stumbled upon and what was the next one, on and on.

The error message was:

/src/build/tmp/work/riscv64imafdc-foobar-linux/libcxx/22.1.3/recipe-sysroot-native/usr/bin/riscv64-foobar-linux/riscv64-foobar-linux-ld: cannot find crtbeginS.o: No such file or directory
/src/build/tmp/work/riscv64imafdc-foobar-linux/libcxx/22.1.3/recipe-sysroot-native/usr/bin/riscv64-foobar-linux/riscv64-foobar-linux-ld: cannot find -lstdc++: No such file or directory
/src/build/tmp/work/riscv64imafdc-foobar-linux/libcxx/22.1.3/recipe-sysroot-native/usr/bin/riscv64-foobar-linux/riscv64-foobar-linux-ld: cannot find -lgcc: No such file or directory
riscv64-foobar-linux-clang++: error: linker command failed with exit code 1 (use -v to see invocation)

As far as I understand, this is precisely what do_preconfigure (+ some patches)
is supposed to handle, so at first it looked like a regression, but it seems the
error only reproduces when switching distros.

For some context, I was building something with
PREFERRED_TOOLCHAIN_TARGET="clang", using wrynose branch. If I use the custom
distro from the beginning (so no switching), everything works fine (as expected).

Best regards,

Changes in v2:
- squashed the patch* into 0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
- added vardeps to do_unpack as well (5th patch)

* 0001-llvm-clang-Add-Distro-instance-to-getMultiarchTriple.patch

João Marcos Costa (5):
  llvm-project-source.inc: fix string replacements in do_preconfigure
  llvm-project-source.inc: fix end of line in triple variable
  clang/llvm: add missing instance of Distro class in Linux.cpp
  llvm-project-source.inc: add vardeps to do_preconfigure
  llvm-project-source.inc: add vardeps to do_unpack

 ...t-anchor-for-adding-OE-distro-vendor.patch | 35 ++++++++++++++-----
 .../clang/llvm-project-source.inc             |  8 +++--
 2 files changed, 31 insertions(+), 12 deletions(-)

-- 
2.43.0



^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2026-06-29  9:51 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-23 12:08 [PATCH v2 0/5] llvm/clang: fix some syntax issues in llvm-project-source João Marcos Costa
2026-06-23 12:08 ` [PATCH v2 1/5] llvm-project-source.inc: fix string replacements in do_preconfigure João Marcos Costa
2026-06-23 12:08 ` [PATCH v2 2/5] llvm-project-source.inc: fix end of line in triple variable João Marcos Costa
2026-06-23 12:08 ` [PATCH v2 3/5] clang/llvm: add missing instance of Distro class in Linux.cpp João Marcos Costa
2026-06-23 12:08 ` [PATCH v2 4/5] llvm-project-source.inc: add vardeps to do_preconfigure João Marcos Costa
2026-06-28 10:25   ` [OE-core] " Richard Purdie
2026-06-29  8:09     ` Joao Marcos Costa
2026-06-29  9:39       ` Richard Purdie
2026-06-29  9:51         ` Joao Marcos Costa
2026-06-23 12:08 ` [PATCH v2 5/5] llvm-project-source.inc: add vardeps to do_unpack João Marcos Costa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox