Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We recently added support for an illumos host triple to the Rust toolchain, and would like to be able to build ring there. This patch adds support for that. We are sufficiently similar to Solaris that we just needed some extra conditional compilation directives.
The tests don't currently pass:
The reason for this is a somewhat complicated artefact of the unwinding machinery and dynamic linker dependencies, and my plan is to go and fix this directly in the Rust toolchain. The issue is in the order of
NEEDED
entries in the resultant executable:Because
libc.so.1
is beforelibgcc_s.so.1
in the list, we will use the unwinding symbols that are provided as part of the system ABI. Unfortunately for our purposes, there are some additional symbols in the GCC unwinder that are not in the base platform library -- these symbols fall through and are bound to the GCC version, and thus we have two totally separate implementations trying to work on one another's data structures and the result is a crash (or worse). I intend to fix this in the Rust toolchain, to make sure the correct ordering of NEEDED entries is always present in built binaries. Once that's fixed there I expect better behaviour here, as we see with unwinding in binaries that don't have as much custom/FFI stuff.I expect the same issue afflicts the Solaris stuff today, though they might have added the additional symbols to their base libc unwinder.