Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regression: Cannot build the compiler for aarch64-apple-tvos-sim using Rust 1.78.0 #124825

Closed
Kentzo opened this issue May 6, 2024 · 4 comments
Closed
Labels
O-tvos Operating system: tvOS (including simulator)

Comments

@Kentzo
Copy link

Kentzo commented May 6, 2024

There is a regression in 1.78.0 where compilation of the tvOS target (Tier 3) fails. It was working with 1.75.0 and 1.77.2 source distributions.

config.toml
profile = "library"

[build]
target = ["aarch64-apple-tvos-sim", "aarch64-apple-darwin"]
docs = false
locked-deps = true
vendor = true
extended = true
tools = [
    "cargo"
]

[install]
prefix = "..."
sysconfdir = "etc"

[rust]
channel = "stable"
lto = "thin"
/usr/bin/xcrun --sdk appletvsimulator --run python3 x.py build
Building stage2 library artifacts (aarch64-apple-darwin -> aarch64-apple-tvos-sim)
...
error: methods `as_raw_stat`, `st_birthtime`, `st_birthtime_nsec`, `st_flags`, `st_gen`, and `st_lspare` are never used
  --> library/std/src/os/ios/fs.rs:29:8
   |
15 | pub trait MetadataExt {
   |           ----------- methods in this trait
...
29 |     fn as_raw_stat(&self) -> &raw::stat;
   |        ^^^^^^^^^^^
...
60 |     fn st_birthtime(&self) -> i64;
   |        ^^^^^^^^^^^^
61 |     #[stable(feature = "metadata_ext2", since = "1.8.0")]
62 |     fn st_birthtime_nsec(&self) -> i64;
   |        ^^^^^^^^^^^^^^^^^
...
68 |     fn st_flags(&self) -> u32;
   |        ^^^^^^^^
69 |     #[stable(feature = "metadata_ext2", since = "1.8.0")]
70 |     fn st_gen(&self) -> u32;
   |        ^^^^^^
71 |     #[stable(feature = "metadata_ext2", since = "1.8.0")]
72 |     fn st_lspare(&self) -> u32;
   |        ^^^^^^^^^
   |
   = note: `-D dead-code` implied by `-D warnings`
   = help: to override `-D warnings` add `#[allow(dead_code)]`

error: method `set_created` is never used
   --> library/std/src/os/ios/fs.rs:151:8
    |
148 | pub trait FileTimesExt: Sealed {
    |           ------------ method in this trait
...
151 |     fn set_created(self, t: SystemTime) -> Self;
    |        ^^^^^^^^^^^

error: could not compile `std` (lib) due to 2 previous errors
@Kentzo Kentzo added the C-bug Category: This is a bug. label May 6, 2024
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label May 6, 2024
@workingjubilee
Copy link
Member

Does it work with nightly?

@Kentzo
Copy link
Author

Kentzo commented May 6, 2024

I'll try to reproduce if time permits.

@saethlin
Copy link
Member

saethlin commented May 6, 2024

This is a duplicate of #121640. All you need to do is turn off deny-warnings. (Typical Tier 3 experience 🙃)

@Kentzo
Copy link
Author

Kentzo commented May 6, 2024

Huh, somehow missed that one. Thanks!

@Kentzo Kentzo closed this as completed May 6, 2024
@saethlin saethlin added O-tvos Operating system: tvOS (including simulator) and removed C-bug Category: This is a bug. needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels May 6, 2024
bors added a commit to rust-lang-ci/rust that referenced this issue Jul 14, 2024
…ilee

Merge Apple `std::os` extensions modules into `std::os::darwin`

The functionality available on Apple platforms are very similar, and were (basically) duplicated for each platform.

This PR rectifies that by merging the code into one module.

Ultimately, I've done this to fix `./x build library --target=aarch64-apple-tvos,aarch64-apple-watchos,aarch64-apple-visionos`, as that currently fails because of dead code warnings.

Publically exposing these to tvOS/watchOS/visionOS targets is considered in rust-lang#123723, but that seems to be dragging out, and in any case I think it makes sense to do the refactor separately from stabilization.

r? libs

Fixes rust-lang#121640 and rust-lang#124825.
github-actions bot pushed a commit to rust-lang/miri that referenced this issue Jul 16, 2024
Merge Apple `std::os` extensions modules into `std::os::darwin`

The functionality available on Apple platforms are very similar, and were (basically) duplicated for each platform.

This PR rectifies that by merging the code into one module.

Ultimately, I've done this to fix `./x build library --target=aarch64-apple-tvos,aarch64-apple-watchos,aarch64-apple-visionos`, as that currently fails because of dead code warnings.

Publically exposing these to tvOS/watchOS/visionOS targets is considered in rust-lang/rust#123723, but that seems to be dragging out, and in any case I think it makes sense to do the refactor separately from stabilization.

r? libs

Fixes rust-lang/rust#121640 and rust-lang/rust#124825.
lnicola pushed a commit to lnicola/rust-analyzer that referenced this issue Jul 16, 2024
Merge Apple `std::os` extensions modules into `std::os::darwin`

The functionality available on Apple platforms are very similar, and were (basically) duplicated for each platform.

This PR rectifies that by merging the code into one module.

Ultimately, I've done this to fix `./x build library --target=aarch64-apple-tvos,aarch64-apple-watchos,aarch64-apple-visionos`, as that currently fails because of dead code warnings.

Publically exposing these to tvOS/watchOS/visionOS targets is considered in rust-lang/rust#123723, but that seems to be dragging out, and in any case I think it makes sense to do the refactor separately from stabilization.

r? libs

Fixes rust-lang/rust#121640 and rust-lang/rust#124825.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-tvos Operating system: tvOS (including simulator)
Projects
None yet
Development

No branches or pull requests

4 participants