2016-11-23 61 views
0

我正在研究離子應用。我在嘗試爲android構建時遇到錯誤。Ionic構建Android時出錯?

FAILURE: Build failed with an exception. 

* What went wrong: 
Unable to start the daemon process. 
This problem might be caused by incorrect configuration of the daemon. 
For example, an unrecognized jvm option is used. 
Please refer to the user guide chapter on the daemon at http://gradle.org/docs/2.2.1/userguide/gradle_daemon.html 
Please read the following process output to find out more: 
----------------------- 
Error occurred during initialization of VM 
Could not reserve enough space for object heap 
Error: Could not create the Java Virtual Machine. 
Error: A fatal exception has occurred. Program will exit. 
+0

能你請檢查你是否安裝了「java」,並且驅動器上有足夠的可用空間? –

+0

我已經安裝了Android Studio和JRE,我們還需要什麼 – RaviMittal

+0

根據我的知識,沒有必要爲離子應用程序提供Android Studio,我們只需要android sdk。 –

回答

0
Error occurred during initialization of VM 
Could not reserve enough space for object heap 

從消息,似乎它是由JVM堆空間時gradle這個建離子項目造成的,請嘗試增加堆大小Java中

用於Windows系統的簡單步驟:

  1. 配置在本地環境的GRADLE_OPTS或JAVA_OPTS具有下列參數

    -Xms512m -Xmx512m -XX:PermSize =256米-XX:MaxPermSize參數=512米

(如果您正在使用JDK8,該PermSize將被忽略。)

參考 Configuring the build environment

+0

我正在使用Windows。你能否請更新你的答案,步驟 – RaviMittal

+0

@RaviMittal對不起,只需更新答案。 –

+0

試用此解決方案 – RaviMittal