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

Add Apple visionOS support #1773

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

QuentinPerez
Copy link

Motivation

Add the support of Apple VisionOS 121419

Solution

Add target_os = "visionos"

@Thomasdezeeuw
Copy link
Collaborator

Can you add VisionOS to our CI and local testing in:

  • mio/Makefile

    Line 2 in 15050b9

    TARGETS ?= aarch64-apple-darwin aarch64-apple-ios aarch64-linux-android arm-linux-androideabi i686-unknown-linux-gnu wasm32-wasi x86_64-apple-darwin x86_64-apple-ios x86_64-pc-windows-gnu x86_64-pc-windows-msvc x86_64-unknown-freebsd x86_64-unknown-illumos x86_64-unknown-linux-gnu x86_64-unknown-linux-musl x86_64-unknown-netbsd x86_64-unknown-redox
  • target: ["aarch64-apple-ios", "aarch64-apple-tvos", "aarch64-unknown-openbsd", "arm64_32-apple-watchos", "armv7-sony-vita-newlibeabihf", "sparcv9-sun-solaris", "x86_64-pc-solaris", "x86_64-unknown-dragonfly", "x86_64-unknown-openbsd"]

(same for the socket2 pr, but I'll add a comment there as well)

@@ -1,9 +1,9 @@
name: CI
on:
push:
branches: [ "master", "v0.7.x", "v0.8.x" ]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you undo all these formatting changes? It's hard to see what has actually changed.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just pushed a wip to test the CI, I will revert the formatting

@Thomasdezeeuw
Copy link
Collaborator

libc seems to not build (correctly) for visionOS, see CI.

@QuentinPerez
Copy link
Author

see rust-lang/libc#3568 (comment)

@QuentinPerez
Copy link
Author

QuentinPerez commented Apr 10, 2024

@Thomasdezeeuw same question; do you mind if I use target_vendor = "apple" ? Instead of changing this every time Apple releases a new device

@simlay
Copy link

simlay commented May 21, 2024

libc seems to not build (correctly) for visionOS, see CI.

It should now be fix with rust-lang/rust#124560. Though, I think CI may still fail because the default Xcode version for the macOS-latest runner is currently Xcode 15.0.1 but visionOS was added with Xcode 15.2 which means that xcrun --show-sdk-path --sdk xros will fail when called from rustc. One could fix this in CI with something like sudo xcode-select -s /Applications/Xcode_15.2.app but that's a bit too specific and brittle for my taste.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants