我已经关注了Gluon Mobile文档,并且能够使用NetBeans 8.2在桌面上运行该示例。
当我执行 launchPhoneSimulator 任务时,控制台上会出现以下内容(我已经安装了Xcode 8.2.1):
Executing: gradle :launchIPhoneSimulator
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:createDefaultIOSLauncher UP-TO-DATE
:compileIosJava UP-TO-DATE
:processIosResources UP-TO-DATE
:iosClasses UP-TO-DATE
:iosExtractNativeLibs UP-TO-DATE
:launchIPhoneSimulator FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':launchIPhoneSimulator'.
> org.apache.commons.exec.ExecuteException: Command '/var/folders/k8/2n_6gyt11sg3j0y1rs_cq9yw90_n8s/T/ios-sim7848548085597099282 showdevicetypes' failed with output: 2017-01-25 10:25:29.090 ios-sim7848548085597099282[39624:2618148] +[SimDeviceSet defaultSet]: unrecognized selector sent to class 0x105fff5b8
2017-01-25 10:25:29.090 ios-sim7848548085597099282[39624:2618148] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[SimDeviceSet defaultSet]: unrecognized selector sent to class 0x105fff5b8'
*** First throw call stack:
(
0 CoreFoundation 0x00007fffbb41fe7b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x00007fffcfffacad objc_exception_throw + 48
2 CoreFoundation 0x00007fffbb4a1bf4 +[NSObject(NSObject) doesNotRecognizeSelector:] + 132
3 CoreFoundation 0x00007fffbb391fb5 ___forwarding___ + 1061
4 CoreFoundation 0x00007fffbb391b08 _CF_forwarding_prep_0 + 120
5 ios-sim7848548085597099282 0x0000000101944c21 -[iPhoneSimulator showDeviceTypes] + 75
6 ios-sim7848548085597099282 0x0000000101946dd1 -[iPhoneSimulator runWithArgc:argv:] + 3111
7 ios-sim7848548085597099282 0x0000000101946fb9 main + 101
8 ios-sim7848548085597099282 0x0000000101944150 start + 52
9 ??? 0x0000000000000002 0x0 + 2
)
libc++abi.dylib: terminating with uncaught exception of type NSException (Exit value: 134)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 8.615 secs
相反,当我尝试使用 launchIODevice 任务运行我的iPhone时,控制台中会出现以下内容:
Executing: gradle :launchIOSDevice
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:createDefaultIOSLauncher UP-TO-DATE
:compileIosJava UP-TO-DATE
:processIosResources UP-TO-DATE
:iosClasses UP-TO-DATE
:iosExtractNativeLibs UP-TO-DATE
:launchIOSDevice FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':launchIOSDevice'.
> No provisioning profile found matching signing identity 'iPhone Developer: music@adregulamartis.it (5MQZC923QJ)' and app bundle ID 'com.gluonsingleview.GluonSingleView'
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 1.848 secs
我错过了什么?