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

Toolchain: Upstreaming tracking for gcc/binutils/llvm #14183

Open
11 of 16 tasks
ADKaster opened this issue Jun 4, 2022 · 6 comments
Open
11 of 16 tasks

Toolchain: Upstreaming tracking for gcc/binutils/llvm #14183

ADKaster opened this issue Jun 4, 2022 · 6 comments
Labels
posix POSIX compliance task list This issue contains a list of tasks.

Comments

@ADKaster
Copy link
Member

ADKaster commented Jun 4, 2022

In order to be a fully accepted CMake target, we should have compiler support upstreamed to at least gcc or llvm-project.

Here's the list of things that need done for that do have a chance of succeeding:

This issue is being tracked at the same time on CMake's GitLab here

In SerenityOS/serenity:

Loader/Kernel/LibELF:

LibC:


GNU Autotools:

  • config.sub
  • config.guess
  • libtool.m4

Binutils:

GCC/libstdc++:

  • Split patch up (d0edf26)
  • Upstream patches

LLVM:

LLVM Lit tests:

@ADKaster ADKaster added task list This issue contains a list of tasks. posix POSIX compliance labels Jun 4, 2022
@ghost
Copy link

ghost commented Jun 6, 2022

In order for <ctype.h.> to be POSIX compliant, doesn't <locale.h> have to also be POSIX compliant?

@ADKaster
Copy link
Member Author

ADKaster commented Jun 6, 2022

I believe our locale.h is compliant -- the C library only accepts the C locale.

The issue with ctype relates to us pretending to be newlib but not having the elements in the _ctype_ global array arranged properly. LLVM chokes on it and we have to tell it to provide its own ctype.h

@ADKaster
Copy link
Member Author

Turns out plenty of systems tell libc++ to provide its own "Rune table" ... so us doing so as well isn't that big a deal.

@ADKaster
Copy link
Member Author

We should update the CMake patches to reflect the fact that LibDL is now an ld-script stub like Musl's by removing the LibDL lib variable from the Platform files.

@timschumi
Copy link
Member

LibDL is now an ld-script

Not sure if this is a typo, but better safe than sorry. Both LibDl and LibM are completely normal libraries at the moment, the only library that has been merged into LibC so far is LibPthread.

That said, I do plan to do the same with LibDl and LibM some time in the near future.

@ADKaster
Copy link
Member Author

I created an RFC for LLVM upstreaming here: https://discourse.llvm.org/t/rfc-add-support-for-serenityos/71641

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
posix POSIX compliance task list This issue contains a list of tasks.
Projects
None yet
Development

No branches or pull requests

2 participants