Skip to content

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

@gautam899

Description

@gautam899

Summary

Attempting to perform bootstrap rust build for target "aarch64-wrs-vxworks".

Command used

./x.py build target=x86_64-unknown-linux-gnu,aarch64-wrs-vxworks

Expected behaviour

The rust build passes without any failures.

Actual behaviour

Bootstrap configuration (bootstrap.toml)

llvm.download-ci-llvm = true
build.optimized-compiler-builtins = false

Operating system

VxWorks

HEAD

d3877ec

Additional context

The failure is only seen for vxworks version greater than or equal to 25.09.

Build Log

Building stage1 library artifacts{alloc, compiler_builtins, core, panic_abort, panic_unwind, proc_macro, rustc-std-workspace-core, std, std_detect, sysroot, test, unwind} (stage1:x86_64-unknown-linux-gnu -> stage1:aarch64-wrs-vxworks)
   Compiling compiler_builtins v0.1.160 (<path>/rust/library/compiler-builtins/compiler-builtins)
   Compiling core v0.0.0 (<path>/rust/library/core)
   Compiling libc v0.2.178
   Compiling object v0.37.3
   Compiling std v0.0.0 (<path>/rust/library/std)
   Compiling test v0.0.0 (<path>/rust/library/test)
   Compiling rustc-std-workspace-core v1.99.0 (<path>/rust/library/rustc-std-workspace-core)
   Compiling alloc v0.0.0 (<path>/rust/library/alloc)
   Compiling memchr v2.7.6
   Compiling adler2 v2.0.1
   Compiling cfg-if v1.0.4
   Compiling panic_abort v0.0.0 (<path>/rust/library/panic_abort)
   Compiling rustc-demangle v0.1.27
   Compiling rustc-literal-escaper v0.0.7
   Compiling unwind v0.0.0 (<path>/rust/library/unwind)
   Compiling rustc-std-workspace-alloc v1.99.0 (<path>/rust/library/rustc-std-workspace-alloc)
   Compiling panic_unwind v0.0.0 (<path>/rust/library/panic_unwind)
   Compiling gimli v0.32.3
   Compiling std_detect v0.1.5 (<path>/rust/library/std_detect)
   Compiling hashbrown v0.16.1
   Compiling miniz_oxide v0.8.9
   Compiling addr2line v0.25.1
error[E0609]: no field `st_atime` on type `&stat`
  --> library/std/src/os/vxworks/fs.rs:73:36
   |
73 |         self.as_inner().as_inner().st_atime as i64
   |                                    ^^^^^^^^ unknown field
   |
help: a field with a similar name exists
   |
73 -         self.as_inner().as_inner().st_atime as i64
73 +         self.as_inner().as_inner().st_atim as i64
   |

error[E0609]: no field `st_mtime` on type `&stat`
  --> library/std/src/os/vxworks/fs.rs:79:36
   |
79 |         self.as_inner().as_inner().st_mtime as i64
   |                                    ^^^^^^^^ unknown field
   |
help: a field with a similar name exists
   |
79 -         self.as_inner().as_inner().st_mtime as i64
79 +         self.as_inner().as_inner().st_mtim as i64
   |

error[E0609]: no field `st_ctime` on type `&stat`
  --> library/std/src/os/vxworks/fs.rs:85:36
   |
85 |         self.as_inner().as_inner().st_ctime as i64
   |                                    ^^^^^^^^ unknown field
   |
help: a field with a similar name exists
   |
85 -         self.as_inner().as_inner().st_ctime as i64
85 +         self.as_inner().as_inner().st_ctim as i64
   |

error[E0609]: no field `st_mtime` on type `stat`
   --> library/std/src/sys/fs/unix.rs:643:35
    |
643 |         SystemTime::new(self.stat.st_mtime as i64, 0)
    |                                   ^^^^^^^^ unknown field
    |
help: a field with a similar name exists
    |
643 -         SystemTime::new(self.stat.st_mtime as i64, 0)
643 +         SystemTime::new(self.stat.st_mtim as i64, 0)
    |

error[E0609]: no field `st_atime` on type `stat`
   --> library/std/src/sys/fs/unix.rs:678:35
    |
678 |         SystemTime::new(self.stat.st_atime as i64, 0)
    |                                   ^^^^^^^^ unknown field
    |
help: a field with a similar name exists
    |
678 -         SystemTime::new(self.stat.st_atime as i64, 0)
678 +         SystemTime::new(self.stat.st_atim as i64, 0)
    |

warning: unnecessary `unsafe` block
   --> library/std/src/sys/fd/unix.rs:165:13
    |
165 |         cvt(unsafe {
    |             ^^^^^^ unnecessary `unsafe` block
    |
    = note: `#[warn(unused_unsafe)]` (part of `#[warn(unused)]`) on by default

warning: unnecessary `unsafe` block
   --> library/std/src/sys/fd/unix.rs:407:9
    |
407 |         unsafe {
    |         ^^^^^^ unnecessary `unsafe` block

For more information about this error, try `rustc --explain E0609`.
warning: `std` (lib) generated 2 warnings
error: could not compile `std` (lib) due to 5 previous errors; 2 warnings emitted

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.O-vxworksTarget: when they made us, they called us Curiosity, and Spirit, and told us to tell you helloT-libsRelevant to the library team, which will review and decide on the PR/issue.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions