Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/sql-server-2008/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Objective c 获取错误:";架构x86“U 64”的未定义符号;在使用CocoaLumberjack框架时_Objective C_Cocoalumberjack - Fatal编程技术网

Objective c 获取错误:";架构x86“U 64”的未定义符号;在使用CocoaLumberjack框架时

Objective c 获取错误:";架构x86“U 64”的未定义符号;在使用CocoaLumberjack框架时,objective-c,cocoalumberjack,Objective C,Cocoalumberjack,我已经在现有项目中使用cocoapods安装了cocoaLumberjack框架 # Uncomment the next line to define a global platform for your project platform :ios, '12.0' def shared_pods pod 'CocoaLumberjack' end target 'ABC' do shared_pods end 通过上述pod实现成功安装了框架 我在我的prefix.pch文件中添

我已经在现有项目中使用cocoapods安装了cocoaLumberjack框架

# Uncomment the next line to define a global platform for your project
platform :ios, '12.0'

def shared_pods
  pod 'CocoaLumberjack'
end

target 'ABC' do
  shared_pods
end
通过上述pod实现成功安装了框架

我在我的
prefix.pch
文件中添加了以下内容

#define LOG_LEVEL_DEF ddLogLevel
#import <CocoaLumberjack/CocoaLumberjack.h>

static DDLogLevel ddLogLevel = DDLogLevelDebug;
如果我尝试在我的模拟器中运行项目,在实现了这个之后,我会得到以下错误

Undefined symbols for architecture x86_64:
      "_OBJC_CLASS_$_DDLog", referenced from:
          objc-class-ref in AppDelegate.o
      "_OBJC_CLASS_$_DDFileLogger", referenced from:
          objc-class-ref in AppDelegate.o
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)

您是否尝试将代码从
prefix.pch
移动到任何其他头文件?
Undefined symbols for architecture x86_64:
      "_OBJC_CLASS_$_DDLog", referenced from:
          objc-class-ref in AppDelegate.o
      "_OBJC_CLASS_$_DDFileLogger", referenced from:
          objc-class-ref in AppDelegate.o
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)