I have problem with Android Studio. After updating AS to 2.2 it takes a long (~30 min) time to process indicating that it is "Building Symbols..." The project is reasonably large and includes NDK components.
Building using gradle is quite fast:
BUILD SUCCESSFUL
time: 12.089 secs
My gradle_wrapper settings:
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
android.useDeprecatedNdk=true
org.gradle.daemon=true
org.gradle.parallel=true
#android.dexOptions.preDexLibraries=true
#android.enableBuildCache=true
org.gradle.jvmargs=-Xmx4096m -XX:MaxPermSize=1024m-
HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
Whats wrong with Android Studio? How can I speed up it?
It is possible your VM is running out memory or you're under memory pressure. You can try increasing the amount of memory available to Android Studio under Help
you can choose Edit Custom VM Options
.
-Xms256m
-Xmx8192m
-XX:ReservedCodeCacheSize=2048m
-XX:+UseCompressedOops
-XX:MaxPermSize=4096m
Close Android Studio and in the project directory and delete all .idea folders. On macOS or Linux that might be accomplished with the find
command.
find . -name .idea -type d -exec rm -rf {} +
Then launch Android Studio and re-import the project.
Android Studio's NDK support is based upon CLion which uses CMake as its project file format. I found that switching my large project to pure CMake put a permanent end to the Building Symbols problem. It makes sense, since it is probably more thoroughly tested by JetBrains and easier to support than Android.mk projects.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With