krzyzanowskim / OpenSSL

OpenSSL package for SwiftPM, CocoaPod, and Carthage, multiplatform
https://swift.best
Other
907 stars 334 forks source link

Question: macOS Configuration #165

Closed phedlund closed 11 months ago

phedlund commented 1 year ago

When archiving for macOS the OpenSSL framework is placed in /Contents/Frameworks/OpenSSL.framework but when attempting to launch the app the system is looking in /Contents/MacOS/Frameworks/OpenSSL.framework. Since it can't be found there the app crashes. How can I configure this correctly? (If it matters, my app is using the SwiftUI app life cycle).

phedlund commented 1 year ago

Updating Runpath Search Path to

LD_RUNPATH_SEARCH_PATHS = (
    "$(inherited)",
    "@executable_path/Frameworks",
    "@executable_path/../Frameworks",
);

resolves the issue. Can that be added to the package somehow?

krzyzanowskim commented 11 months ago

@executable_path/../Frameworks is the default for macOS, and it's already setup like that.

Screenshot 2023-09-06 at 20 03 05

It may be setting on your project? or can you attach an Xcode project where its failing? I can't reproduce