简体   繁体   English

迦太基Xcode 9错误

[英]Carthage Xcode 9 Error

I try to install Carthage in my project but it always crash on launch. 我尝试在我的项目中安装Carthage,但它总是在启动时崩溃。

Nothing works from what I've tried.. 没有什么比我尝试过的更好..

Error: 错误:

dyld: Library not loaded: @rpath/StarscreamSocketIO.framework/StarscreamSocketIO
Referenced from: /private/var/containers/Bundle/Application/69ADA4FD-59A0-4840-9A64-XXXXX/XXXX.app/Frameworks/SocketIO.framework/SocketIO
Reason: image not found

Carthage folder: 迦太基文件夹:

在此输入图像描述

Linked Frameworks and Libraries: 链接的框架和库: 在此输入图像描述

Run Script: 运行脚本: 在此输入图像描述

Copy Files: 复制文件: 在此输入图像描述

I also tried to set the framework in Embedded Binaries. 我还尝试在嵌入式二进制文件中设置框架。

Thank you. 谢谢。

Edit: Cartfile file: 编辑:Cartfile文件: 在此输入图像描述

Swift 3 斯威夫特3

If you can't port your code to Swift 4, the following is a possible workaround: 如果您无法将代码移植到Swift 4,以下是一种可能的解决方法:

1.inside your main project, drag and drop the file Starscream.xcodeproj which is inside: 1.在你的主项目中,拖放里面的Starscream.xcodeproj文件:

Carthage/Checkouts/socket.io-client-swift/Source/Starscream

2.add the framework StarscreamSocketIO.framework inside the section "Linked Frameworks and Libraries" 2.在“链接的框架和库”部分中添加了框架StarscreamSocketIO.framework

3.compile and run 3.编译并运行

Swift 4 斯威夫特4

socket.io v11 had a bug with Carthage: github.com/socketio/socket.io-client-swift/issues/787 although it's possible to fix it with some manual workarounds, I recommend you to upgrade to the latest socket.io v13 socket.io v11有一个关于Carthage的错误: github.com/socketio/socket.io-client-swift/issues/787虽然可以通过一些手动解决方法修复它,但我建议你升级到最新的socket.io v13

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM