Game built with gradle running extremely slow (at least 30 min to start)

I’m trying to build my game with gradle build system in Unity 2017.1.0p4. The reason for this is that I’m getting the error about “Too many field references to fit in one dex file” when using the internal build system.

After a lot of fiddling with plugins and androidmanifest, I got it to build and install on my phone.

Now the problem is that it takes forever to start. It’s a fairly big game, and I have some stuff in resources, and it seems like that is the big issue. I’m loading a big resource while loading the first scene, and that makes it freeze at the splash screen for around 30 minutes (I stopped counting, so it could be 20 or 40). And yes - “Minutes

Normally, when internal build works (before updating all the google aars to new version, with jar-resolver), it takes about 10 seconds to start the app.

Does anyone have any ideas where to begin with finding a solution for this?

cheers /jonas

I resolved this by simply updating to Unity 2017.2