0

我需要使用 CocoaAsyncSocket 接收 TCP 数据包。当我将该库导入 Xcode 并尝试运行我的应用程序时,它给了我 Apple Mach-O 链接器错误:

Undefined symbols for architecture i386:
"_kCFStreamErrorDomainMach", referenced from:
  -[AsyncSocket errorFromCFStreamError:] in AsyncSocket.o
"_kCFStreamErrorDomainNetDB", referenced from:
  -[AsyncSocket errorFromCFStreamError:] in AsyncSocket.o
"_kCFStreamErrorDomainNetServices", referenced from:
  -[AsyncSocket errorFromCFStreamError:] in AsyncSocket.o
"_kCFStreamErrorDomainSystemConfiguration", referenced from:
  -[AsyncSocket errorFromCFStreamError:] in AsyncSocket.o
"_kCFStreamPropertySSLSettings", referenced from:
  -[AsyncSocket maybeStartTLS] in AsyncSocket.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

那么,我能做什么???

4

1 回答 1

0

您只需要在 Frameworks 中添加 SecurityFramework。我也遇到了类似的问题。

于 2013-08-27T06:49:51.820 回答