2

我正在尝试在 IONIC 应用程序中使用 Bluemix 的混合 SDK,但是在第一步中我遇到了错误。

创建离子应用程序后:

ionic start PushTeste tabs
ionic add platform ios
ionic plugin add com.ibm.mobile.cordova.ibmcloudcode 
ionic plugin add com.ibm.mobile.cordova.ibmpush
ionic build ios

我收到以下错误:

/Users/DaniloOliveira/tmp/PushIonic/platforms/ios/PushIonic/Plugins/com.ibm.mobile.cordova.ibmpush/CDVIBMPush.m:49:89: error: property 'token' not found on object of type 'AppDelegate *'
    NSString* token = [[[[((AppDelegate *)[[UIApplication sharedApplication] delegate]).token description]
                                                                                        ^ 1 error generated.

** BUILD FAILED **


The following build commands failed:    CompileC /Users/DaniloOliveira/PushIonic/platforms/ios/build/PushIonic.build/Debug-iphoneos/PushIonic.build/Objects-normal/armv7/CDVIBMPush.o PushIonic/Plugins/com.ibm.mobile.cordova.ibmpush/CDVIBMPush.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler (1 failure) Error: /Users/DaniloOliveira/tmp/PushIonic/platforms/ios/cordova/run: Command failed with exit code 65
    at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:135:23)
    at ChildProcess.emit (events.js:98:17)
    at maybeClose (child_process.js:756:16)
    at Process.ChildProcess._handle.onexit (child_process.js:823:5)

我不是本地开发人员,也不是 Cordova 插件开发人员,所以我不知道 appe 应用程序的结构......

我的环境:

  • 代码 6
  • Mac 10.9.5
  • iphone 6 IOS 8.1.1

有什么建议吗?

4

2 回答 2

1

很简单,只需按照文档进行即可。您需要在 SDK 中进行一些调整才能使 SDK 正常工作。

http://mbaas-gettingstarted.ng.bluemix.net/hybrid#get-started-with-push

于 2014-12-20T19:26:31.883 回答
0

您必须重新安装一个插件,然后重新安装所有其他插件,对于这些插件没有

ios plugins 目录中的目录以避免此错误代码。

更多详情如下:

http://forum.ionicframework.com/t/ionic-build-ios-plugin-errors-exit-code-65/7274

于 2014-12-21T03:19:24.627 回答