fix: fix differing bitwidth types/routines under Windows x86 GNU#5059
Open
dybucc wants to merge 1 commit intorust-lang:mainfrom
Open
fix: fix differing bitwidth types/routines under Windows x86 GNU#5059dybucc wants to merge 1 commit intorust-lang:mainfrom
dybucc wants to merge 1 commit intorust-lang:mainfrom
Conversation
This comment has been minimized.
This comment has been minimized.
46c4c58 to
9a434dd
Compare
Until rust-lang#5032, whenever `libc` was running under Windows x86 with GNU, the default bit-width of `time_t` values was 32-bits. This doesn't quite align with the defaults in MSVC and `mingw`, but that's been addressed in that PR. This PR is a quick patch for stable, as the changes in rust-lang#5032 are not backwards-compatible. It separates the routines that under Windows use `time_t` values and changes their link-time symbols to the 32-bit variants exposed in both MSVC and `mingw`, for the affected target platform/environment. It also adds a test, akin to the one in rust-lang#5032, that should ensure the correct bit-widths are in use for both the types and the linked routine symbols.
9a434dd to
c8cb7bc
Compare
3 tasks
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.
Description
Until #5032, whenever
libcwas running under Windows x86 with GNU, the defaultbit-width of
time_tvalues was 32-bits. This doesn't quite align with thedefaults in MSVC and
mingw, but that's been addressed in that PR.This PR is a quick patch for stable, as the changes in #5032 are not
backwards-compatible. It separates the routines that under Windows use
time_tvalues and changes their link-time symbols to the 32-bit variants exposed in
both MSVC and
mingw, for the affected target platform/environment.It also adds a test, akin to the one in #5032, that should ensure the correct
bit-widths are in use for both the types and the linked routine symbols.
Sources
None. If any, the same as #5032 as this stems from it.
Checklist
libc-test/semverhave been updated*LASTor*MAXare included (see#3131)
cd libc-test && cargo test --target mytarget);especially relevant for platforms that may not be checked in CI
@rustbot label +stable-nominated