mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 18:07:34 +00:00
Ports: Upgrade LLVM to version 13.0.0
With this update, we now use our custom `serenity` Clang target, which means that all system-specific compilation options (e.g. default PIE, header search paths) will be handled automatically. This port has been tested to build `Source/little` on all 4 toolchain-architecture pairs. Furthermore, `lib(std)c++` headers are picked up correctly and our AK headers can be included without any issues. Due to recent kernel fixes related to memory-mapped files, the LLD linker can now be used by default, so there's no need to also build the GCC port alongside this. Although our patches cover building libLLVM as a shared library, this is currently not enabled by default, as DynamicLoader is very slow in dealing with such a large number of relocations.
This commit is contained in:
parent
f29f9762a2
commit
e88ca09609
8 changed files with 159 additions and 60 deletions
|
@ -1,9 +1,54 @@
|
|||
# Patches for LLVM on SerenityOS
|
||||
|
||||
## `remove-wstring.patch`
|
||||
## `build-crt.patch`
|
||||
|
||||
Removes `wstring`s from the source code, as SerenityOS doesn't support them yet.
|
||||
This patch lets us use LLVM's `crtbegin.o`/`crtend.o` implementation.
|
||||
|
||||
### Status
|
||||
- [ ] Local?
|
||||
- [x] Should be merged to upstream?
|
||||
- [ ] Resolves issue(s) with our side of things
|
||||
- [ ] Hack
|
||||
|
||||
## `insert-ifdef-serenity.patch`
|
||||
|
||||
This patch adds several defines in order to omit things not supported by SerenityOS.
|
||||
|
||||
### Status
|
||||
- [ ] Local?
|
||||
- [ ] Should be merged to upstream?
|
||||
- [X] Resolves issue(s) with our side of things
|
||||
- [x] Hack
|
||||
|
||||
## `remove-version-script.patch`
|
||||
|
||||
Instructs the linker to not build LLVM shared libraries (`libclang.so`, `libLTO.so`, etc.) with
|
||||
symbol versioning, which our dynamic linker does not support.
|
||||
|
||||
### Status
|
||||
- [ ] Local?
|
||||
- [x] Should be merged to upstream?
|
||||
- [X] Resolves issue(s) with our side of things
|
||||
- [ ] Hack
|
||||
|
||||
## `remove-wstring.patch`
|
||||
|
||||
Removes `std::wstring`s from the source code, as our libstdc++ does not support it.
|
||||
|
||||
### Status
|
||||
- [ ] Local?
|
||||
- [ ] Should be merged to upstream?
|
||||
- [X] Resolves issue(s) with our side of things
|
||||
- [X] Hack
|
||||
|
||||
## `toolchain.patch`
|
||||
|
||||
Adds support for the `$arch-pc-serenity` target to the Clang front end. This makes the compiler
|
||||
look for libraries and headers in the right places, and enables some security mitigations, like
|
||||
stack-smashing protection and building position-independent executables by default.
|
||||
|
||||
### Status
|
||||
- [ ] Local?
|
||||
- [x] Should be merged to upstream?
|
||||
- [ ] Resolves issue(s) with our side of things
|
||||
- [ ] Hack
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue