Fix bootstrap rust build failure for vxworks#153333
Fix bootstrap rust build failure for vxworks#153333gautam899 wants to merge 1 commit intorust-lang:mainfrom
Conversation
|
rustbot has assigned @Mark-Simulacrum. Use Why was this reviewer chosen?The reviewer was selected based on:
|
This comment has been minimized.
This comment has been minimized.
|
ping @biabbas |
This comment has been minimized.
This comment has been minimized.
|
Can you add documentation for the environment variable to https://doc.rust-lang.org/nightly/rustc/platform-support/vxworks.html? cc rust-lang/rfcs#3750 as well, which seems like the long term solution here |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Hi @Mark-Simulacrum, I don't think there is a need to add documentation about the environment variable since this is set by vxworks workbench itself. The user is not required to set this environment variable from their end. |
|
@rustbot ready |
It would be useful to have documented that it reads this env, even if it isn't meant to be set, since this is pretty uncommon. |
Cool. I'll go ahead and add some info about the environment variable. |
|
Some changes occurred in src/doc/rustc/src/platform-support cc @Noratrieb |
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
Hi @Mark-Simulacrum @tgross35 , I have added the documentation for the environment variable |
|
@bors r+ There's generally speaking no need to re-ping folks so aggressively. Reviews can and do take a week+ normally; this PR hasn't been open for that long, and the latest changes were made less than a week ago. Please be patient in the future :) |
Apologies. I'll take care of that in the future. |
Fix bootstrap rust build failure for vxworks Fixes rust-lang#153332 Starting with VxWorks 25.09, struct stat was updated to use struct timespec instead of time_t for timestamp fields. The following changes were made in libc in the commit [libc](rust-lang/libc#4781). As a result, when performing a bootstrap build with VxWorks ≥ 25.09, libc no longer exposes the fields st_mtime, st_atime, and st_ctime, as they are conditionally compiled in src/vxworks/mod.rs here [libc](https://github.com/rust-lang/libc/blob/56caa81b6b433c49c5704bf0400a02d428cfacda/src/vxworks/mod.rs#L229). This causes the build to fail. For VxWorks versions earlier than 25.09, the build completes successfully without errors. This PR resolves the issue by detecting the WIND_RELEASE_ID environment variable (which is set in the VxWorks build environment) and conditionally guarding the affected functions in the two additional files where the errors originate.
Fix bootstrap rust build failure for vxworks Fixes rust-lang#153332 Starting with VxWorks 25.09, struct stat was updated to use struct timespec instead of time_t for timestamp fields. The following changes were made in libc in the commit [libc](rust-lang/libc#4781). As a result, when performing a bootstrap build with VxWorks ≥ 25.09, libc no longer exposes the fields st_mtime, st_atime, and st_ctime, as they are conditionally compiled in src/vxworks/mod.rs here [libc](https://github.com/rust-lang/libc/blob/56caa81b6b433c49c5704bf0400a02d428cfacda/src/vxworks/mod.rs#L229). This causes the build to fail. For VxWorks versions earlier than 25.09, the build completes successfully without errors. This PR resolves the issue by detecting the WIND_RELEASE_ID environment variable (which is set in the VxWorks build environment) and conditionally guarding the affected functions in the two additional files where the errors originate.
Fix bootstrap rust build failure for vxworks Fixes rust-lang#153332 Starting with VxWorks 25.09, struct stat was updated to use struct timespec instead of time_t for timestamp fields. The following changes were made in libc in the commit [libc](rust-lang/libc#4781). As a result, when performing a bootstrap build with VxWorks ≥ 25.09, libc no longer exposes the fields st_mtime, st_atime, and st_ctime, as they are conditionally compiled in src/vxworks/mod.rs here [libc](https://github.com/rust-lang/libc/blob/56caa81b6b433c49c5704bf0400a02d428cfacda/src/vxworks/mod.rs#L229). This causes the build to fail. For VxWorks versions earlier than 25.09, the build completes successfully without errors. This PR resolves the issue by detecting the WIND_RELEASE_ID environment variable (which is set in the VxWorks build environment) and conditionally guarding the affected functions in the two additional files where the errors originate.
…uwer Rollup of 12 pull requests Successful merges: - #152870 (Do not enable split debuginfo for windows-gnu) - #153333 (Fix bootstrap rust build failure for vxworks) - #153681 (ci: add runners for vanilla LLVM 22) - #153824 (Add `Wake` diagnostic item for `alloc::task::Wake`) - #154077 (Optimize 128-bit integer formatting) - #154078 (`define_callbacks` tweaks) - #151905 (Split the `dec2flt::RawFloat` trait for easier reuse) - #153170 (Add is_disconnected functions to mpsc and mpmc channels) - #153804 (Derive Macro Eq: link to more detailed documentation) - #153974 (Point at return type when it is the source of the type expectation) - #154018 (simplify and remove `tests/ui/kindck` and related tests) - #154041 (bootstrap: Allow `--bless`ing changes to editor settings files)
Fixes #153332
Starting with VxWorks 25.09, struct stat was updated to use struct timespec instead of time_t for timestamp fields.
The following changes were made in libc in the commit libc.
As a result, when performing a bootstrap build with VxWorks ≥ 25.09, libc no longer exposes the fields st_mtime, st_atime, and st_ctime, as they are conditionally compiled in src/vxworks/mod.rs here libc. This causes the build to fail.
For VxWorks versions earlier than 25.09, the build completes successfully without errors.
This PR resolves the issue by detecting the WIND_RELEASE_ID environment variable (which is set in the VxWorks build environment) and conditionally guarding the affected functions in the two additional files where the errors originate.