要将 ScriptingBridge 与 iTunes 一起使用,我使用了:
iTunesApplication *iTunes = [SBApplication applicationWithBundleIdentifier:@"com.apple.iTunes"];
但是,当我运行应用程序时,(我已经将错误的来源追溯到上面的行),我得到一个构建失败,并且这些错误:
Apple Mach-O Linker (Id) Error
"_OBJC_CLASS_$_SBApplication", referenced from:
objc-class-ref in AppDelegate.o
ld: symbol(s) not found for architecture x86_64
和
Apple Mach-O Linker (Id) Error
Linker command failed with exit code 1 (use -v to see invocation)
我该如何解决这个问题?我从 Apple Developer Scripting Bridge 编程指南中复制并粘贴了该行,所以我无法想象它会导致问题。