Skip to main content

Questions tagged [gradle]

Gradle is a project build automation tool that uses a Groovy DSL. Gradle build scripts support Maven and Ivy repositories as well as plain file system for dependency management.

gradle
1080 votes
36 answers
791k views

Android Studio: Add jar as library?

I'm trying to use the new Android Studio but I can't seem to get it working correctly. I'm using the Gson library to serialize/deserialize JSON-objects. But the library somehow isn't included in the ...
Ozzie's user avatar
  • 11.7k
171 votes
15 answers
289k views

How to enable multidexing with the new Android Multidex support library

I want to use the new Multidex support library to break the method limit for one of my apps. With Android Lollipop Google introduced a multidex support library that makes it easy to multidex. What ...
Janusz's user avatar
  • 189k
824 votes
22 answers
955k views

How to add local .jar file dependency to build.gradle file?

I have tried to add my local .jar file dependency to my build.gradle file: apply plugin: 'java' sourceSets { main { java { srcDir 'src/model' } } } dependencies { ...
letter Q's user avatar
  • 15.1k
836 votes
16 answers
888k views

Using Gradle to find dependency tree

Is it possible to use Gradle to produce a tree of what depends on what? I have a project and would like to find out all the dependencies so I may be able to prune it a little with forward declarations ...
user3286701's user avatar
  • 8,443
1293 votes
12 answers
536k views

What's the difference between implementation, api and compile in Gradle?

After updating to Android Studio 3.0 and creating a new project, I noticed that in build.gradle there is a new way to add new dependencies instead of compile there is implementation and instead of ...
humazed's user avatar
  • 76.2k
50 votes
5 answers
57k views

React Native Android build failure with different errors without any changes in code for past days due to publish of React Native version 0.71.0-rc.0

Note: Error may be different but if you are getting any error when taking android build without any changes in code for past two days My Error - Failed to install the app. Error: Command failed: ./...
ZFloc Technologies's user avatar
533 votes
28 answers
532k views

How to manually include external aar package using Gradle for Android

I've been experimenting with the new android build system and I've run into a small issue. I've compiled my own aar package of ActionBarSherlock which I've called 'actionbarsherlock.aar'. What I'm ...
Miguel's user avatar
  • 20k
557 votes
23 answers
840k views

How do I tell Gradle to use specific JDK version?

I can't figure out to get this working. Scenario: I have an application built with gradle The application uses JavaFX What I want Use a variable (defined per developer machine) which points to an ...
bully's user avatar
  • 5,894
136 votes
23 answers
137k views

Java finished with non-zero exit value 2 - Android Gradle

I'm getting this error executing my Android app (I cleaned it and then built it, but the error is still present) Sync: OK Make Project: OK Clean: OK Run: Error Error:Execution failed for task ':...
Maverick.pe's user avatar
  • 1,917
807 votes
24 answers
560k views

Error retrieving parent for item: No resource found that matches the given name after upgrading to AppCompat v23

I've always programmed Android with Eclipse and decided to start migrating to Android Studio. I decided to use the same SDK I already had for Eclipse, then: Started a new project Set minimum SDK 4.0 (...
Vini.g.fer's user avatar
  • 11.8k
216 votes
26 answers
173k views

Multiple dex files define Landroid/support/v4/accessibilityservice/AccessibilityServiceInfoCompat

If I run gradle assembleDebug from the command line, I am suddenly getting this error: UNEXPECTED TOP-LEVEL EXCEPTION: com.android.dx.util.DexException: Multiple dex files define Landroid/support/v4/...
xrd's user avatar
  • 4,069
166 votes
14 answers
238k views

OpenCV in Android Studio

I want to use OpenCV library in my app with Android Studio. I followed instructions found here but I get error Configuration with name 'default' not found What can be wrong? I use Android Studio ...
Bartosz Bialecki's user avatar
629 votes
20 answers
213k views

Can the Android layout folder contain subfolders?

Right now, I'm storing every XML layout file inside the 'res/layout' folder, so it is feasible and simple to manage small projects, but when there is a case of large and heavy projects, then there ...
Paresh Mayani's user avatar
459 votes
18 answers
1.0m views

How to update gradle in android studio?

I installed Android Studio 0.1.9. Today I got and update to version 0.2 and of course I updated. After the installation I restarted Android Studio but now I get this message: Project is using an ...
7heViking's user avatar
  • 7,427
223 votes
28 answers
302k views

Android Studio suddenly cannot resolve symbols

Android Studio 0.4.2 was working fine and today I opened it and almost everything was red and the auto-completion had stopped working. I look at the imports and AS seems to be telling me it can't find ...
Daniel Wilson's user avatar

15 30 50 per page
1
2 3 4 5
405