Skip to content

Fix bootstrap rust build failure for vxworks#153333

Open
gautam899 wants to merge 1 commit intorust-lang:mainfrom
gautam899:main
Open

Fix bootstrap rust build failure for vxworks#153333
gautam899 wants to merge 1 commit intorust-lang:mainfrom
gautam899:main

Conversation

@gautam899
Copy link

@gautam899 gautam899 commented Mar 3, 2026

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.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Mar 3, 2026
@rustbot
Copy link
Collaborator

rustbot commented Mar 3, 2026

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @ChrisDenton, libs
  • @ChrisDenton, libs expanded to 8 candidates
  • Random selection from Mark-Simulacrum, joboet

@rust-log-analyzer

This comment has been minimized.

@gautam899
Copy link
Author

ping @biabbas

@rust-log-analyzer

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rust build fails for target "aarch64-wrs-vxworks"

4 participants