Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rework LLVM packaging #10

Open
ermo opened this issue Jan 12, 2024 · 1 comment
Open

Rework LLVM packaging #10

ermo opened this issue Jan 12, 2024 · 1 comment
Labels
area: package Packaging related area: plumbing OS / system architecture related

Comments

@ermo
Copy link
Member

ermo commented Jan 12, 2024

(originally reported by @ikeycode)

Currently our LLVM packaging is somewhat of a superpackage, and an absolute nightmare to maintain.

The proposal is to split into several individual packages within the
llvm namespace.

Goal

  • Easier to maintain
  • Trivial integration with boulder emul32 / PGO support.
  • Support multiple LLVM versions (multiple toolchains require it)
  • Not having to stay behind upstream due to one package.
  • Update LLVM without bricking the split toolchain

llvm/llvm-libs

Simply contains the LLVM libraries, optimised as necessary. Required for
compat with all LLVM based toolchains. Initially we'll only ship a single
version of the LLVM libraries until virtual provider support is added to
permit shifting between the libs.

llvm15 == llvm, etc.
llvm14

llvm/clang

Provides the actual clang compiler, multilib capable. Again, the goal is to
eventually support multiple clang versions, decoupled from the libs.

Statically linked against llvm-libs

llvm/libcxx

Providing the libc++ libraries from LLVM.

Statically linked against llvm-libs

llvm/llvm-libgcc

Provide the libgcc shim to unfudge btrfs-progs, etc. This is due to our
use of glibc.

Statically linked against llvm-libs

llvm/lld

Separated linker. Follow latest clang/llvm. No multiversion

Statically linked against llvm-libs

llvm/ldb

Separated debugger. Follow latest clang/llvm. No multiversion

Statically linked against llvm-libs

Safety checklist:

  • Ensure lld, clang et all are statically linked before proceeding with the split.
@ermo
Copy link
Member Author

ermo commented Jan 12, 2024

ermo
Is it known whether lld and ldb will work seamlessly between versions?

Does upstream have a policy on being backwards compatible or are we in "maybe it works with older toolchains? 🤷" territory?

Ikey Doherty
lld can work with, in theory, any ELF library. We'll statically link to newest llvm-libs.
ldb is a debugger and should just follow the same policy.

@der-eismann der-eismann added the area: package Packaging related label Feb 2, 2024
@ermo ermo added the area: plumbing OS / system architecture related label Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: package Packaging related area: plumbing OS / system architecture related
Projects
None yet
Development

No branches or pull requests

2 participants