I want to build a Swift library package that uses modified build of OpenSSL and Curl.
I have already statically compiled both and verified I can use them in an Objective-C framework on my target platform (iOS & iOS Simulator). I'm using XCFramework files that contain the static library binaries and headers:
openssl.xcframework/
ios-arm64/
openssl.framework/
Headers/
[...]
openssl
ios-arm64_x86_64-simulator/
openssl.framework/
Headers/
[...]
openssl
Info.plist
I'm not sure how I'm supposed to set up my Swift package to import these libraries.
I can use .systemLibrary
but that seems to use the embedded copies of libssl and libcurl on my system, and I can't figure out how to use the path:
parameter to that.
I also tried using a .binaryTarget
pointing to the XCFramework files, but that didn't seem to work as there is no module generated and I'm not sure how to make one myself.
At a basic high level, this is what I'm trying to accomplish:
where libcrypto
& libssl
come from the provided openssl.xcframework
file, and libcurl
from curl.xcframework