build: Replace RUST_LIBC_UNSTABLE env with libc_unstable* cfg#4977
Merged
Conversation
tgross35
force-pushed
the
libc-cfg
branch
3 times, most recently
from
February 14, 2026 22:29
3d160eb to
f2aa125
Compare
3 tasks
This comment has been minimized.
This comment has been minimized.
3 tasks
This comment has been minimized.
This comment has been minimized.
tgross35
force-pushed
the
libc-cfg
branch
5 times, most recently
from
June 23, 2026 05:25
deaf2aa to
426a449
Compare
The current environment variable setup makes it easy to set a configuration for both the host (build scripts) and target, even when that is not the intent. Change to a rustc cfg, which is easier to set for only the target. This was briefly discussed on Zulip around [1]. [1]: https://rust-lang.zulipchat.com/#narrow/channel/219381-t-libs/topic/Questions.20and.20polls.20about.20.60libc.60.201.2E0/near/511723332
RUST_LIBC_UNSTABLE env with libc_unstable* cfgRUST_LIBC_UNSTABLE env with libc_unstable* cfg
tgross35
marked this pull request as ready for review
June 23, 2026 05:45
Contributor
Author
|
Woo I think this works finally. FreeBSD is the only remaining |
Contributor
Author
|
I'm going to go ahead since this seems functional, and there are a few things that want to stack on top of it |
tgross35
added a commit
to tgross35/rust-libc
that referenced
this pull request
Jul 20, 2026
The current environment variable setup makes it easy to set a configuration for both the host (build scripts) and target, even when that is not the intent. Change to a rustc cfg, which is easier to set for only the target. This was briefly discussed on Zulip around [1]. [1]: https://rust-lang.zulipchat.com/#narrow/channel/219381-t-libs/topic/Questions.20and.20polls.20about.20.60libc.60.201.2E0/near/511723332 (backport <rust-lang#4977>) (cherry picked from commit f08bfce)
tgross35
added a commit
to tgross35/rust-libc
that referenced
this pull request
Jul 20, 2026
The current environment variable setup makes it easy to set a configuration for both the host (build scripts) and target, even when that is not the intent. Change to a rustc cfg, which is easier to set for only the target. This was briefly discussed on Zulip around [1]. [1]: https://rust-lang.zulipchat.com/#narrow/channel/219381-t-libs/topic/Questions.20and.20polls.20about.20.60libc.60.201.2E0/near/511723332 (backport <rust-lang#4977>) (cherry picked from commit f08bfce)
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.
The current environment variable setup makes it easy to set a
configuration for both the host (build scripts) and target, even when
that is not the intent. Change to a rustc cfg, which is easier to set
for only the target.
This was briefly discussed on Zulip around 1.