Remove unneeded JDKs and use Gradle