Add the support for Clang cross-compiler
Get series with b4
b4 am [email protected]Versions newest first
- v2 Latest1 of 12 patches 0 repliesNew
1 of 12 patches is in this archive. The cover letter announces 12.
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 7/12 | package/busybox: fix applets runtime issue when building with clang cross-compiler | +0 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [Buildroot] [PATCH v2 00/12] Add the support for Clang cross-compiler
Hi Arnout,
Le 29/08/2020 ? 20:53, Arnout Vandecappelle a ?crit?:
Quoted 11 lines
Hi Romain,
After almost a year, let's try to make some progress on this series :-)
On 07/09/2019 11:40, Romain Naour wrote:
[snip]Quoted 3 lines
Recently, I've tried to build an aarch64 Linux kernel (5.2.7) with Clang and it worked under Qemu [3]. I also tested for
x86_64but we need the upcomming llvm/clang version 9 to build the kernel [4].Since we waited long enough, this is now in Buildroot :-)
We are in late about llvm version, the version 11 should be released anytime soon.
Quoted 23 lines
Quoted 11 lines
This new version add the support of "asm-goto" which was the last missing part to be able to build the Linux kernel on
x86_64[5]. But for theses tests, only the kernel was built with Clang.While testing the
x86_64kernel and it's rootfs built with Clang under Qemu, I had a runtime issue during the userspace boot process (Busybox's init). While searching about the issue, I discover the lowRISC blog from Lu?s Marques about the same issue and tested the patch he contributed to the Busybox project (Thanks!).Quoted 3 lines
So, this series is about to complete the integration of Clang as cross-compiler by using a toolchain-wrapper and fixing some build system infrastructure (cmake, meson) to use Clang instead of GCC.
I started integrating the series, but then I had some fundamental problems with
the core patch itself. So I stopped and pushed my results to
https://gitlab.com/arnout/buildroot branch clang-as-cross-compiler. I put my changes as squash patches rather than changing the original patches, so you can easily take over from there. Note that I haven't tested my rebased and modified branch (just a build test immediately after applying the modified patch), so there may still be some rebase f**up there.
Quoted 1 line
I'll put my feedback in the individual patches.
Thanks!
I'm not sure how many free time I will able to devote to this series. I recently did a test with llvm/clang 10 for risv64 [1] but the series needs some work to be upstreamable...
I'd like to be able to work on this series as a full day job :)
[1] https://asciinema.org/a/DDspJVktlVl1Rh97dwLgtYcRY
Best regards,
Romain
Quoted 12 lines
Regards,
ArnoutQuoted 6 lines
Add this new experimental option into "Advanced" menu since we are expecting some build and runtime issues for number of packages (bootloaders, kernel).
For now, Clang cross-compiler can only be use as internal toolchain, so it is build from the source which take a long time...
[snip]