RxSwift icon indicating copy to clipboard operation
RxSwift copied to clipboard

VisionOS Support

Open nighthawk opened this issue 7 months ago • 1 comments

This PR adds support for visionOS to many more things by dropping a bunch of || os(visionOS) over the place.

Note of caution: While I'm using this in one app, and it's working fine there now, I have not tested everything that has been enabled here. However, as the visionOS SDK is still in beta that's probably not a big issue.

This fixes #2530, and is related to #2543.

nighthawk avatar Dec 06 '23 21:12 nighthawk

@freak4pc previously had to revert #2543, due to this:

Hey @RobertDresler - I had to revert this for now as this will cause build errors in Xcode 14.3 which is still a dominantly used Xcode version (which also requires users to update to Sonoma, which wasn't even officially released yet).

Sonoma and Xcode 15 are now releases. So this might be a good time now. Or feel free to keep this open until adoption of Sonoma is higher.

nighthawk avatar Dec 06 '23 21:12 nighthawk

As this is still Open does it mean that visionOS is not yet supported?

notapplicableio avatar Mar 28 '24 03:03 notapplicableio

@nighthawk do you know the timeframe for this getting merged?

notapplicableio avatar Apr 11 '24 04:04 notapplicableio

I'm not a maintainer of this project, so I can't answer that. @freak4pc might know.

FWIW, this is working fine in my usage so far and the changes are relatively straightforward.

nighthawk avatar Apr 11 '24 04:04 nighthawk

I have a little question about this @nighthawk. I'm sure it's environmental, but just in case...

I have updated to RxSwift 6.7.0 but it's not compiling on visionOS. Xcode claims to have 6.7.0 and I see evidence of your changes throughout, but not in Platform.Darwin.swift which is causing the compile issue.

I've done the usual; reset package cache, updated to latest, specific version, etc.

Am I going mad?

UPDATE: I looked a little harder and it hasn't made it to the main branch.

image

notapplicableio avatar Apr 30 '24 22:04 notapplicableio

I have a little question about this @nighthawk. I'm sure it's environmental, but just in case...

I have updated to RxSwift 6.7.0 but it's not compiling on visionOS. Xcode claims to have 6.7.0 and I see evidence of your changes throughout, but not in Platform.Darwin.swift which is causing the compile issue.

I've done the usual; reset package cache, updated to latest, specific version, etc.

Am I going mad?

UPDATE: I looked a little harder and it hasn't made it to the main branch.

image

Darwin is Linux, is it actually trying to compile that file?

I had to remove it because it broke Linux / Unix builds

freak4pc avatar May 01 '24 04:05 freak4pc

@freak4pc Indeed, 6.7.0 doesn't actually compile for visionOS due to that change from https://github.com/ReactiveX/RxSwift/pull/2589. visionOS does need that extension on Thread, too, as it's for example used in CurrentThreadScheduler.queue.

nighthawk avatar May 01 '24 09:05 nighthawk

Seems this is only a waning and not an error, adding it back.

freak4pc avatar May 01 '24 09:05 freak4pc

@notapplicableio Can you test the main branch to let me know if it fixes the issue? If yes I'll cut a 6.7.1. Thanks

freak4pc avatar May 01 '24 09:05 freak4pc

@freak4pc I just tested the latest main branch and it's compiling for visionOS again.

nighthawk avatar May 01 '24 09:05 nighthawk

Release 6.7.1, thanks both!

freak4pc avatar May 01 '24 15:05 freak4pc

And for me, too. Thank you @freak4pc and @nighthawk :)

notapplicableio avatar May 02 '24 02:05 notapplicableio