dyld: Library not loaded: @rpath/libswiftSwiftOnoneSupport.dylib

后端 未结 8 1827
太阳男子
太阳男子 2020-12-02 23:43

I\'ve built a Swift framework and now I\'m trying to start building a Swift iOS application that will use that framework. I\'m getting this error:

dyld: Libr         


        
8条回答
  •  再見小時候
    2020-12-03 00:13

    I eventually got this working using a mix of fixes. I'm not sure if all of them are needed, but I'm documenting what seemed to work for me here, just in case anyone else can benefit by what I've found.

    1. I have set Always Embed Swift Standard Libraries to a value of YES in the build settings tab for both my Swift framework and in the Swift application that uses the framework.
    2. I have added Foundation.framework to the Linked Frameworks and Libraries section of the general tab for both my Swift framework and in the Swift application that uses the framework.
    3. I have added Foundation.framework to the Embedded Binaries section of the general tab for the Swift application that uses the framework.

    With all 3 of these settings in place, I am able to build and run my application without encountering this error.

提交回复
热议问题