tokio-rs / tokio

A runtime for writing reliable asynchronous applications with Rust. Provides I/O, networking, scheduling, timers, ...
https://tokio.rs
MIT License
25.44k stars 2.3k forks source link

tokio build broken for aarch64-apple-visionos #6627

Closed coolbluewater closed 4 weeks ago

coolbluewater commented 4 weeks ago

Version tokio 1.63

Platform Building for aarch64-apple-visionos Building on macos (if that helps)

Description Tokio does not build for the recently added Rust visionos target aarch64-apple-visionos. Building using

cargo +nightly build --target aarch64-apple-visionos -Zbuild-std

yields this error, and a number of others:

error: unsupported target for `mio::unix::pipe`
  --> /Users/xxx/.cargo/registry/src/index.crates.io-6f17d22bba15001f/mio-0.8.11/src/sys/unix/pipe.rs:75:5
   |
75 |     compile_error!("unsupported target for `mio::unix::pipe`");
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0432]: unresolved imports `self::selector::event`, `self::selector::Event`, `self::selector::Events`, `self::selector::Selector`
  --> /Users/xxx/.cargo/registry/src/index.crates.io-6f17d22bba15001f/mio-0.8.11/src/sys/unix/mod.rs:18:37
   |
18 |     pub(crate) use self::selector::{event, Event, Events, Selector};
   |                                     ^^^^^  ^^^^^  ^^^^^^  ^^^^^^^^ no `Selector` in `sys::unix::selector`
   |                                     |      |      |
   |                                     |      |      no `Events` in `sys::unix::selector`
   |                                     |      no `Event` in `sys::unix::selector`
   |                                     no `event` in `sys::unix::selector`
   |
Darksonn commented 4 weeks ago

Adding a new target requires changes to both Tokio and mio. The changelog entry you saw added the changes needed in Tokio, but the changes in mio have still not happened, so it's not really supported yet.

coolbluewater commented 4 weeks ago

Can we please keep this open until fixed?

coolbluewater commented 4 weeks ago

@Darksonn wrote

Adding a new target requires changes to both Tokio and mio. The changelog entry you saw added the changes needed in Tokio, but the changes in mio have still not happened, so it's not really supported yet.

Also, what changelog entries are you referring to? I'm simply reporting that tokio does not build for this target.

Darksonn commented 3 weeks ago

We close issues when the relevant changes are merged, not when a release containing them is released.

Darksonn commented 3 weeks ago

The fix in Tokio happened in #6465.

coolbluewater commented 3 weeks ago

@Darksonn, the build of a fresh clone of the master branch is still broken so I don't understand what you mean.

coolbluewater commented 3 weeks ago

Your responses make no sense. Please read this issue again.

Darksonn commented 3 weeks ago

A fresh clone of Tokio's master branch will use a released version of mio, and not the latest master branch of mio.

coolbluewater commented 3 weeks ago

I get that. What I don't understand is you saying that "The fix in tokio happened in #6465".

That was not sufficient to make the build actually work. tokio needs to update to the version of mio that has the fix. I opened another issue in mio and they replied with the version that has the fix.

This issue means that tokio does not build for vision os. Period. Fixing it means making the build actually work, not some small part of the work.

Your replies are obtuse and unhelpful, and not to the point.

Darksonn commented 3 weeks ago

No, Tokio does not need to update to that mio version because Tokio depends on a range of mio versions. We are not pinned to a specific release. Once mio makes a v0.8.x release containing VisionOS support, it will work with Tokio as-is. No further changes are needed in the Tokio repository.