xcode 架构 i386 的未定义符号:“_utf8_nextCharSafeBody”,引用自:“
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/24264231/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Undefined symbols for architecture i386: "_utf8_nextCharSafeBody", referenced from:"
提问by JoPrithivi
How to clear this error. Please help me, I don't know about socket process
如何清除此错误。请帮帮我,我不知道socket进程
Undefined symbols for architecture i386: "_utf8_nextCharSafeBody", referenced from: _validate_dispatch_data_partial_string in SRWebSocket.o ld: symbol(s) not found for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)
架构 i386 的未定义符号:“_utf8_nextCharSafeBody”,引用自:SRWebSocket.old 中的 _validate_dispatch_data_partial_string:未找到架构 i386 clang 的符号:错误:链接器命令失败,退出代码为 1(使用 -v 查看调用)
采纳答案by Max MacLeod
It's nothing to do with sockets. The target binary you are building cannot be linked because it's missing a binary for the i386 architecture. Basically, you may have a .o file for that symbol - _utf8_nextCharSafeBody
- for armv, but you don't have a .o object file binary for the simulator (i386). Check the supported architectures in your static library dependency and add i386.
这与套接字无关。您正在构建的目标二进制文件无法链接,因为它缺少 i386 架构的二进制文件。基本上,您可能有该符号的 .o 文件_utf8_nextCharSafeBody
- 用于 armv,但您没有用于模拟器 (i386) 的 .o 目标文件二进制文件。检查静态库依赖项中支持的架构并添加 i386。
It's worth reading up on the basics of building in Xcode, specifically compilation and linkage phases.
值得阅读有关在 Xcode 中构建的基础知识,特别是编译和链接阶段。
回答by Kiddo
I added this framework and it seems to solve my problem
我添加了这个框架,它似乎解决了我的问题
- libicucore.dylib
- libicucore.dylib
回答by Velmurugan S
Add this framework: libicucore.dylib,CFNetwork.framework .
添加这个框架: libicucore.dylib,CFNetwork.framework 。
If not solved then Try to import the library that a used in the SRWebSocket class. and then fallow this steps to clean Product > Clean Product > Build . and then build the project.
如果没有解决,那么尝试导入在 SRWebSocket 类中使用的库。然后休耕此步骤以清洁 Product > Clean Product > Build 。然后构建项目。