scripts/bootstrap-prefix: make darwin bootstrap with clang - #45
Conversation
| vdb=${vdb%-*} | ||
| evdb=${evdb%-r*} | ||
| evdb=${evdb%_p*} | ||
| evdb=${evdb%-r[[:digit:]]*} |
There was a problem hiding this comment.
what in particular does this fix? does it accidentially match a wrong package?
There was a problem hiding this comment.
It's a little fix for re-stage, for example when first attempt of stage 2 is failed for some package, when I retry it will ignore some already merged packages and then re-emerge again.
The particular example is llvm-runtimes/clang-runtime, which in here -runtime will get stripped and leaving final evdb as llvm-runtimes/clang which is a non-existance package.
Safe to revert, as it just cost a little more re-bootstrap time for debugging :)
de0e8ec to
121d221
Compare
| : # this is Clang, recent enough to compile recent clang | ||
| ;; | ||
| stage3:) | ||
| : # for Clang in stage 3, we should already have a good compiler |
There was a problem hiding this comment.
We should, but this is the same for GCC. Are you trying to avoid a rebuild or something? If the package didn't update, and it's good, it should stay where it is, or is there another reason?
| "default-lld" | ||
| ) | ||
| if [[ "${BOOTSTRAP_STAGE}" == stage2 ]] ; then | ||
| if [[ "${STAGE}" == stage2 ]] ; then |
There was a problem hiding this comment.
so I now understand where this mess comes from, I just cleaned it up in da92e6e and we can use BOOTSTRAP_STAGE always/everywhere now
4fc4545 to
a5da4a7
Compare
Signed-off-by: Zigit Zo <byte@kei.network>
Signed-off-by: Zigit Zo <byte@kei.network>
a5da4a7 to
ed64168
Compare
In Darwin there's plenty of tools that now use macOS infra such as nodejs, many rust libraries... For GCC lacks of macOS builtins and the blocks extension, building many tools require a lot of hack, switching to clang will reduce some pain.
This is still a proof-of-concept style, it works on my macOS 26, but may not be a clean way, and may not work for other macOS version.
Changes explaination:
-stdlib++-isystemto use Gentoo headers, and building libcxx requires-DLIBCXX_ABI_NAMESPACE=to avoid conflicting the system one.STAGEandBOOTSTRAP_STAGE, but I'm not sure if that's the correct way :/( xxx )to workStill this is a proof-of-concept, managed to get bootstrap but may encounter other issues.