Closed ruslandoga closed 3 years ago
Hey, I currently don't have access to arm mac. The binary includes arm64 binaries for iOS, do they work on an arm mac simulator? What happens if you try to run simulator with the library? crash? error? or it falls back to rosetta?
I get symbols not found for iOS-simulator arm64 error during compilation. I'll try building webrtc for mac target with arm64 arch to see if it works.
gn gen . --args='target_os="mac" target_cpu="arm64" ...
Thanks for the answer, macOS binary probably wont work on simulator regardless architecture.
I'm in the process of adding more binary variants to the xcframework, I'll try to add arm64 simulator as well
Hey Again, I think I made XCFramework file with arm64 simulator support. If you can confirm on your arm mac that it works that will be super helpful for me.
Download link: https://www.dropbox.com/s/8ao8k2gsfj0p2kh/WebRTC.xcframework.zip?dl=0
@stasel Hi!
The build was successful (but I had to adapt to RTCPeerConnectionFactory.peerConnection returning an optional now). And audio calls worked fine as well (I don't have video calls in the app).
Thanks for the quick solution!
Awesome! Thanks a lot for testing this for me, I'm happy that it works. The peerconnection optional error was probably because I compiled the library from master so it must be a new change.
I'll release the full XCFramework later today / tomorrow for all of us to enjoy.
Cheers
Release M90 version with arm64 simulator support.
Thanks again for confirming the framework. Feel free to reopen the issue if you are still experiencing problems
@stasel Can you detail what changes were required to get arm64 simulator to build? I have a script that builds ios_x64, ios_arm64 and mac_x64 but not sure how to get an ios arm64 simulator build going. I try to generate the arm64 simulator build by specifying target_os =mac
and target_cpu = arm64
but when the framework gets generated I get Both 'macos-arm64' and 'macos-x86_64' represent two equivalent library definitions.
If you are using xcodebuild -create-xcframework
it will not work unfortunately. To solve this, I combined all binaries using lipo
and manually created the xcframework. Check my build script for see the process
If you are using
xcodebuild -create-xcframework
it will not work unfortunately. To solve this, I combined all binaries usinglipo
and manually created the xcframework. Check my build script for see the process
Where can I view your build script?
👋
I wonder if it would be possible to add arm64 cpu for Mac target to be able to use webrtc in simulators on m1 macs?
Thanks!