cordova platform add android
Subproject Path: CordovaLib
Android project created with cordova-android@6.0.0
Installing "cordova-plugin-whitelist" for android
ANDROID_HOME=C:\Users\Proxymis\AppData\Local\Android\sdk1
JAVA_HOME=C:\Program Files\Java\jre1.8.0_121
Failed to install 'cordova-plugin-whitelist':CordovaError: Requirements check failed for JDK 1.8 or greater
at C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\lib\check_reqs.js:278:19
at _fulfilled (C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:834:54)
at self.promiseDispatch.done (C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:863:30)
at Promise.promise.promiseDispatch (C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:796:13)
at C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:604:44
at runSingle (C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:137:13)
at flush (C:\Users\Proxymis\Desktop\sendSMS\platforms\android\cordova\node_modules\q\q.js:125:13)
at _combinedTickCallback (node.js:370:9)
at process._tickCallback (node.js:401:11)
Error: Requirements check failed for JDK 1.8 or greater
我认为我的环境还可以:
JAVA_HOME
C:\Program Files\Java\jdk1.8.0_121
java -version
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)