Wrong Gradle version detected
Hello,
When trying to build rfp#728 (closed) with gradlew-fdroid
, it does not detect the required Gradle version:
No suitable gradle version found - defaulting to 5.0
Running ../versions/5.0/bin/gradle
FAILURE: Build failed with an exception.
* Where:
Build file '/home/pierre/www/disable-delete-gapps/app/build.gradle' line: 1
* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin [id 'com.android.application']
> Gradle version 2.2 is required. Current version is 5.0. If using the gradle wrapper, try editing the distributionUrl in /home/pierre/www/disable-delete-gapps/gradle/wrapper/gradle-wrapper.properties to gradle-2.2-all.zip
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 0s
I tried using the workaround mentionned in #184 (closed) and it removes the version check error but simply fails later with this error:
A problem occurred configuring project ':app'.
> Failed to notify project evaluation listener.
> org.gradle.api.tasks.compile.JavaCompile.setDependencyCacheDir(Ljava/io/File;)V
So I guess we do need Gradle 2.2.
Is there something in the way com.android.tools.build:gradle
is called (see here) that could make the detection failed?