构建Cordova 3.4应用程序时架构i386的未定义符号

时间:2014-02-25 11:10:04

标签: ios ios7 xcode5 cordova-3

构建Cordova应用程序时,我的Mac上出现构建错误未定义的架构i386符号。我正在使用Cordova 3.4版和Xcode 5.0.2。

以下是我项目的Xcode属性Build Settings - >的快照。架构 enter image description here

Undefined symbols for architecture i386:
  "_AudioServicesAddSystemSoundCompletion", referenced from:
      _playBeep in CDVNotification.o
  "_AudioServicesCreateSystemSoundID", referenced from:
      _playBeep in CDVNotification.o
  "_AudioServicesDisposeSystemSoundID", referenced from:
      _soundCompletionCallback in CDVNotification.o
  "_AudioServicesPlaySystemSound", referenced from:
      -[CDVVibration vibrate:] in CDVVibration.o
      _playBeep in CDVNotification.o
  "_AudioServicesRemoveSystemSoundCompletion", referenced from:
      _soundCompletionCallback in CDVNotification.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

** BUILD FAILED **


The following build commands failed:
    Ld build/emulator/barcodeScanner.app/barcodeScanner normal i386
(1 failure)
Error: /Users/dipin/Projects/barcodeScanner/platforms/ios/cordova/build: Command failed with exit code 65
    at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/src/superspawn.js:112:23)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:735:16)
    at Process.ChildProcess._handle.onexit (child_process.js:802:5)
DIPINs-MacBook-Air:barcodeScanner dipinkumarkrishnan$ cordova -v
3.4.0-0.1.0

请帮我解决此错误。 Android版本适用于同一个项目。

干杯!

1 个答案:

答案 0 :(得分:12)

您可能遗失AudioToolbox.framework。将其添加到目标的构建阶段,然后重试。