问题
编译打包时遇到:
Error:java.lang.OutOfMemoryError: Java heap space . Please assign more memory to Gradle in the project's gradle.properties file. For example, the following line, in the gradle.properties file, sets the maximum Java heap size to 1,024 MB: org.gradle.jvm....
解决方法:
在项目中的gradle.properties文件中,有一行注释的语句,解开注释就好
可能原因:
根据错误提示,大概可以推断出在gradle编译的时候,因为项目太大,需要更多的内存.
但是在我自己的魅族(4pro)手机上没有出现该问题,在公司三星测试机上出现了该问题,所以这个问题也许会根据手机的性能高低出现
如有错误, 敬请指正, 感激不尽!