-
-
Notifications
You must be signed in to change notification settings - Fork 140
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
unshim cxx, add crt[in].o to managarm sysdeps in place of the gcc ones #863
Conversation
oh, right. the ci will need gcc 13 for ubuntu. i'll figure out how to make those packages later.. |
|
||
if host_machine.cpu_family() == 'x86_64' | ||
crt_pie = custom_target('Scrt1', | ||
crtstuff = ['crt0'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these really the best way to name these variables?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
open to better names
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
However, would it be possible to hold this until gha approves too? |
no, it will not do that, but I haven't done a merge yet since I haven't updated the CI to contain new toolchains |
ff3c0eb
to
95e61a9
Compare
should be done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean one needs to install build a cross compiler to build mlibc
now?
.github/workflows/ci.yml
Outdated
@@ -6,21 +6,20 @@ jobs: | |||
build-mlibc: | |||
strategy: | |||
matrix: | |||
arch: [x86_64, riscv64, aarch64] | |||
arch: [x86_64, aarch64] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is riscv
removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the port isn't complete enough to configure a cross compiler
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is missing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unsure, but this is the build log:
239.5 In file included from ../../../tool-src/libgcc/unwind-dw2.c:410:
239.5 ./md-unwind-support.h: In function 'riscv_fallback_frame_state':
239.5 ./md-unwind-support.h:67:6: warning: assignment to 'struct sigcontext *' from incompatible pointer type 'mcontext_t *' [-Wincompatible-pointer-types]
239.5 67 | sc = &rt_->uc.uc_mcontext;
239.5 | ^
239.5 ./md-unwind-support.h:77:53: error: invalid use of undefined type 'struct sigcontext'
239.5 77 | fs->regs.reg[i].loc.offset = (_Unwind_Ptr) &sc->gregs[i] - new_cfa;
239.5 | ^~
239.5 ./md-unwind-support.h:84:21: error: invalid use of undefined type 'struct sigcontext'
239.5 84 | (_Unwind_Ptr) sc->gregs[0] - new_cfa;
239.5 | ^~
239.5 make[2]: *** [../../../tool-src/libgcc/static-object.mk:17: unwind-dw2.o] Error 1
... slightly mangled by docker. to reproduce it, you can use the script in mlibc-crossers by just adding a riscv target
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That seems lie an easy fix, seems like we're just missing a struct sigcontext
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, but I have no knowledge of riscv64, nor a way to test it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, but I'm also not going to merge a regression on the CI. I'll submit a PR to your branch later to fix this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should get fixed once #945 is merged.
nothing changed in that regard, my guess is that old hacks still work |
We never really used any hacks that I'm aware of, and I'm asking since every sysdep now has a cross file that is not the system compiler, implying that we can no longer compile mlibc with the system compiler. |
using a mistargeted compiler should still work as before. the current configuration just gets us GCC 13 with libstdc++ 13 in CI |
But using a mistargeted compiler required cxxshim. Is cxxshim still supported? |
could be the case that we can even use libstdc++ from gcc 13 without cxxshim even when configured hosted and for the wrong target, but I haven't tested it. cxxshim should also work, bugs in it notwithstanding |
95e61a9
to
1c6bf89
Compare
1c6bf89
to
3bceb57
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
No description provided.