passepartoutvpn / openssl-apple

A script for compiling OpenSSL for Apple Devices.
Apache License 2.0
139 stars 65 forks source link

WatchOS Simulator does not link proper architecture #31

Closed fnuky closed 3 years ago

fnuky commented 3 years ago

Hi, thank you so much to this repository for creating xcframework for open ssl, for iphone/catalyst it works pretty well but I have also targets with watchOS and when I'm building for watchsimulator in project, it could not determine symbols because Xcode12 is using x86_64 such as i386 (and arm64 on apple silicone) and xcframework could not be used, I found that openssl supports just x86_64, is there any way how to fix it? Thanks

keeshux commented 3 years ago

I'd rather have you post some output, be it from the scripts or Xcode. As is I'm not sure I get what the issue is.

fnuky commented 3 years ago

Snímek obrazovky 2020-11-30 v 23 38 14

I found that watchos simulator builds x86_64 and i386 and arm64

Snímek obrazovky 2020-11-30 v 23 39 26 Here is screenshot of xcframework builded from xcode

keeshux commented 3 years ago

Make sure to remove bin, lib and frameworks directories before compiling. I removed i386 targets a while ago, so I guess you're having trouble with some stale output.

fnuky commented 3 years ago

There is not a problem with building OpenSSL xcframework but when I try to link xcframework in watch app..

keeshux commented 3 years ago

If there is a i386 slice, there sure is a problem when building the framework. Xcode comes after. So make sure to do what I told you.

fnuky commented 3 years ago

There is no slice in openssl and there is no way how to build it for i386 (I tried to fix it) but when I want to use builded XCFramework in WatchApp, it is not possible to use it for WatchOS simulator and it makes error as on screenshot up. Is there option how to build OpenSSL XCFramework for Watch simulator with arm64 and i386 platform?