Fix haiku and illumos x64 builds - #131700
Merged
Merged
Conversation
|
Azure Pipelines: Successfully started running 6 pipeline(s). 10 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
|
Tagging subscribers to this area: @dotnet/runtime-infrastructure |
am11
force-pushed
the
chore/fix-community-platform-builds
branch
2 times, most recently
from
August 1, 2026 18:21
344d833 to
15f2342
Compare
am11
commented
Aug 1, 2026
am11
force-pushed
the
chore/fix-community-platform-builds
branch
15 times, most recently
from
August 1, 2026 21:51
302d268 to
3c00744
Compare
am11
force-pushed
the
chore/fix-community-platform-builds
branch
from
August 2, 2026 12:52
46d375e to
c23bc52
Compare
3 tasks
jakobbotsch
reviewed
Aug 4, 2026
jkotas
reviewed
Aug 4, 2026
jkotas
reviewed
Aug 4, 2026
Member
Author
|
@jkotas can this be merged? |
jkotas
reviewed
Aug 8, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR makes a set of platform-specific tweaks to restore/build successfully on Haiku and illumos/SunOS x64, primarily by adjusting atomic usage, header/feature guards, and build-time configuration for crashreport.
Changes:
- Add Haiku+clang-specific atomic load/store usage in
minipal_getpagesize. - Tighten Sysctl-dependent networking statistics compilation guards for platforms missing
sys/sysctl.h. - Address SunOS
_Xmacro collisions in corehost PAL headers, and add crashreport CMake configure-time feature detection.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/native/minipal/ospagesize.c | Uses clang __c11_atomic_* on Haiku to cache page size. |
| src/native/libs/System.Native/pal_networkstatistics.c | Gates route/sysctl-based implementations on HAVE_SYS_SYSCTL_H. |
| src/native/corehost/hostmisc/pal.unix.c | Adds DT_* fallback values and switches /proc/self/maps scanning to a runtime-built sscanf format. |
| src/native/corehost/hostmisc/pal.h | Introduces PAL_X and redefines _X after generated config includes, with a SunOS workaround. |
| src/coreclr/jit/gentree.cpp | Suppresses a SunOS GCC warning around CanAssignFrom in a local-load fast-path. |
| src/coreclr/debug/crashreport/inproccrashreporter.cpp | Includes generated config.h and uses feature macros to gate headers. |
| src/coreclr/debug/crashreport/configure.cmake | Adds CMake checks and generates config.h. |
| src/coreclr/debug/crashreport/config.h.in | Template for generated crashreport feature macros. |
| src/coreclr/debug/crashreport/CMakeLists.txt | Wires crashreport configure.cmake and binary include dir into the build. |
Suppressed comments (1)
src/native/corehost/hostmisc/pal.unix.c:385
- The
snprintfthat buildsfmtis invariant across loop iterations but is currently executed once per/proc/self/mapsline. It can be moved before thewhileloop to avoid repeated work in what can be a fairly large file.
// Build the sscanf format dynamically to safely handle parenthesized PATH_MAX values on some platforms (like Haiku)
char fmt[64];
snprintf(fmt, sizeof(fmt), "%%*p-%%*p %%*[-rwxsp] %%*p %%*[:0-9a-f] %%*d %%%ds\n", PATH_MAX);
char buf[PATH_MAX + 1]; // + 1 for the NUL terminator
if (sscanf(line, fmt, buf) == 1)
jkotas
reviewed
Aug 8, 2026
jkotas
approved these changes
Aug 8, 2026
Member
Author
|
@jkotas, thanks! |
jtschuster
pushed a commit
to jtschuster/runtime
that referenced
this pull request
Aug 11, 2026
--------- Co-authored-by: Jan Kotas <jkotas@microsoft.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Regarding
_X, the alternative was to rename it toPAL_Xeverywhere but that turned it into a 1400+ lines of change; can apply if needed.