https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=236165
Alex Richardson <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #2 from Alex Richardson <[email protected]> --- We also ran into this problem in CheriBSD. The binary is actually static (but file will report it as dynamically linked). However, it has a PT_DYNAMIC header and the symbol _DYNAMIC does not resolve to zero. This causes these crashes because there are various checks in libc, csu code, etc. that assume that `if (&_DYNAMIC == NULL)` is true the binary is statically linked and otherwise it assumes we are running a dynamic binary. For our CHERI compilers I just modified ld.lld to not emit _DYNAMIC and the PT_DYNAMIC header. I also attempted to upstream this fix but haven't got around to committing it since I'm not 100% sure what the correct behaviour is. See also https://reviews.llvm.org/D42748 -- You are receiving this mail because: You are the assignee for the bug. _______________________________________________ [email protected] mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-toolchain To unsubscribe, send any mail to "[email protected]"
