Gradle update to 6.4.1
Soooo. after a bit of digging around, I found the reasons for the issues that I faced while updating gradle to latest version. I had mentioned these issues in the mailing list here.
We are using gradle to build gradle. (can be seen from the debian/rules)
But the gradle we have currently can't build the gradle we want. i.e v4.4.1 can't build the v6.4.1 version.
How can I say this? here's what I did:
- install gradle 4.4.1 from archives.
- clone source from salsa. Update it to 6.4.1 using gbp.
- after that, to see what all tasks are there in the newer version, I did a
gradle tasks
(This uses the gradle that I had installed from archives. i.e 4.4.1) The above command doesn't show me any build tasks, I only get the Init and wrapper tasks. - Now I install the latest version from upstream 6.4.1 by building it from source. I use an alias to call it
gradle6
- I run
gradle6 tasks
I get the following results: https://paste.ubuntu.com/p/7yzM24XDPx/ - As seen (and slightly expected) I get a list of all the build tasks include assemble task that we use in debian/rules.
Now keeping this in mind, I set alias for gradle to point to the latest version built from upstream i.e my default gradle
now points to gradle v.6.4.1
Then I ran a debuild -b
after removing the "gradle 4 depends on 3" and unnecessary manual parts from debian/rules. See the changes here.
But to my surprise, the debuild still uses the gradle 4.4.1-api and isn't able to detect the distributions task (or any other tasks present in latest gradle for that matter) See line 564 from the above paste. A line stating preparing gradle 4.4.1-api.jar pops up there while building.
One of the reasons I thought this might be happening was because gradle-user-home was set to debian/.gradlehome in rules. I tried removing that too. I still get the same error.
So TL.DR: Gradle 6.4.1 build from itself but not from 4.4.1. How can I make it build from 6.6.1 without having 6.6.1 first?