Android Development: How to compile with build.gradle

Dear all

I face on compile error "com.android.dex.DexIndexOverflowException: method ID not in [0, 0xffff]: 65536", I search in google the problem is my project reached a limit of method. I following from MultIDex instruction. I need to add build.gradle project, when I build it the error still exist.  Now my question is that is IntelliJ IDEA need to setup for execute build.gradle?  Because I feel the build.gradle never to execute.


And professional can help me

10 comments
Comment actions Permalink

If your project is Gradle based, you just import the build.gradle file in IDEA and it generates and builds the project automatically.

0
Comment actions Permalink

Hi Serge,

I don't my project is Gradle based or not.  How can I check?

0
Comment actions Permalink

Well, if you have build.gradle file and the project builds with Gradle, it's Gradle based =)

0
Comment actions Permalink

The build.gradle is my darg and drop into the project.  So is the build.gradle will be executed?

0
Comment actions Permalink

If you have converted your Android project to Gradle Android project by writing build.gradle file, you should import this file in IDEA as a new project, in this case Gradle will be used to build the project.

0
Comment actions Permalink

I never convert the project to Gradle Android project, how can I do?

0
Comment actions Permalink

Hi, Serge!

My project is not a Gradle based. It is a simple project including couple library projects and a lot of jar-libraries. Is there some way to overcome this 65K DEX restriction?
I am using Intellij IDEA 14.1.5 and I would not want to use Gradle or something else...

0
Comment actions Permalink

As I understood from your link there is no way to overcome 65K limit for now without Gradle or Maven in Intellij IDEA? Am I right?

0

Please sign in to leave a comment.