我正在尝试为Android应用开发设置设备,我已经安装了必要的JDK和SDK,已完成所有操作。但是我在CLI中运行了该命令cordova run --emulator
,它在下面显示了此错误:(我做错了什么?)
C:\Users\Shoms\hello>cordova run --emulator
Android Studio project detected
(node:7508) UnhandledPromiseRejectionWarning: xcodebuild was not found. Please install version 7.0.0 or greater from App Store
(node:7508) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:7508) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
ANDROID_HOME=C:\Users\Shoms\AppData\Local\Android\Sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_172
studio
Subproject Path: CordovaLib
Subproject Path: app
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not open cp_proj remapped class cache for duqjursbq4evw3n3rjfwd4n8x (C:\Users\Shoms\.gradle\caches\4.1\scripts-remapped\build_479s4e2x5zzudfkqa3k2gk3q8\duqjursbq4evw3n3rjfwd4n8x\cp_proj4dada6424967ba8dfea75e81c8880f7f).
> Could not open cp_proj generic class cache for build file 'C:\Users\Shoms\hello\platforms\android\build.gradle' (C:\Users\Shoms\.gradle\caches\4.1\scripts\duqjursbq4evw3n3rjfwd4n8x\cp_proj\cp_proj4dada6424967ba8dfea75e81c8880f7f).
> Unexpected lock protocol found in lock file. Expected 3, found 0.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 1s