[英]Not able to build apk for ionic3 app
我正在嘗試構建apk,但出現此錯誤:
A problem occurred configuring project
':CordovaLib'.
Failed to notify project evaluation listener.
com.android.build.gradle.tasks.factory.AndroidJavaCompile.setDependencyCacheDir(Ljava/io/File;)
BUILD FAILED in 1s
(node:16884) UnhandledPromiseRejectionWarning:
Error: cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.
(node:16884) 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:16884) [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.
我還將environment variables
設置為JAVA_HOME
和ANDROID_HOME
您的項目中存在語法錯誤,請檢查它。 如果您很難找到bug,請新建一個項目:$“ ionic start myApp blank”。 不要添加任何代碼,然后再構建它。 如果再次出現錯誤,則說明您的環境變量存在問題。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.