Issue
- I'm building ghidra according to the installation guide. Everything goes fine Until I get href="https://github.com/NationalSecurityAgency/ghidra/blob/master/DevGuide.md#building-ghidra" rel="noreferrer">here.
- Once I call
$ gradle buildGhidra
I get the following error:
> Could not target platform: 'Java SE 11' using tool chain: 'JDK 8 (1.8)'
This seems weird because I do have java 11:
$ java --version
openjdk 11.0.8 2020-07-14
OpenJDK Runtime Environment (build 11.0.8+10-post-Ubuntu-0ubuntu118.04.1)
OpenJDK 64-Bit Server VM (build 11.0.8+10-post-Ubuntu-0ubuntu118.04.1, mixed mode, sharing)
What am I missing?
Solution
- It turns out that
gradle
was after all the one to blame. - Probably similar to this post, I upgraded to gradle-6.7.
- Then, calling
gradle-6.7 --version
, without any JAVA_HOME change whatsoever, I got:
------------------------------------------------------------
Gradle 6.7-rc-3
------------------------------------------------------------
Build time: 2020-09-30 19:16:51 UTC
Revision: 836e96a80625c9c48b612e662e3b13bd2e2f4c3b
Kotlin: 1.3.72
Groovy: 2.5.12
Ant: Apache Ant(TM) version 1.10.8 compiled on May 10 2020
JVM: 11.0.8 (Ubuntu 11.0.8+10-post-Ubuntu-0ubuntu118.04.1)
OS: Linux 5.4.0-48-generic amd64
Which probably "proves" gradle is indeed the one to blame
Answered By - OrenIshShalom
Answer Checked By - Senaida (JavaFixing Volunteer)