我正在升级我的代码以使用Swift 3和cocoalamberjack3.0.0。当我为iPhone构建时,编译和链接是成功的。当我尝试为模拟器构建时,它会编译,但不会链接。我收到了几条表格上的信息:Undefined symbols for architecture x86_64: "CocoaLumberjack.DDLogDebug (@autoclosure () -> Swift.String, level : __C.DDLogLevel, context : Swift.Int, file : Swift.StaticString, function : Swift.StaticString, line : Swift.UInt, tag : Any?, asynchronous : Swift.Bool, ddlog : __ObjC.DDLog) -> ()", referenced from: ScanmonListener.SMLViewController.buttonTitle.didset : Swift.String in SMLViewController.o ScanmonListener.SMLViewController.viewDidLoad () -> () in SMLViewController.o ScanmonListener.SMLViewController.viewDidAppear (Swift.Bool) -> () in SMLViewController.o ScanmonListener.SMLViewController.viewDidDisappear (Swift.Bool) -> () in SMLViewController.o ScanmonListener.SMLViewController.viewWillAppear (Swift.Bool) -> () in SMLViewController.o ScanmonListener.SMLViewController.viewWillDisappear (Swift.Bool) -> () in SMLViewController.o ScanmonListener.SMLViewController.doPlay () -> Swift.Bool in SMLViewController.o ...
我已运行pod deintegrate
并再次安装,但没有任何效果。
最佳答案
-->解决方案:在每个“Pod_u”目标中,必须将x86_64
(可能还有i386
)添加到Valid Architectures
生成设置中。
关于ios - CocoaLumberjack模拟器的 undefined symbol 构建,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/41491869/