Errors while run project or build apk

65 Views Asked by At

i run android studion with 32b system an 2gb memory when i clean/build project i found 0 error but when i run/build APK 5 errors enter image description here

1

There are 1 best solutions below

1
On

The error says invalid maximum heap size 4GB, but your system is only 2GB, so it exceeds the system memory. you need to configure the acceptable heap size.

You can set the maximum memory usage to 1GB, like -Xmx1024, restart your IDE and it should work