GumTreeDiff / gumtree

An awesome code differencing tool
https://github.com/GumTreeDiff/gumtree/wiki
GNU Lesser General Public License v3.0
936 stars 174 forks source link

Gradle build failed #309

Closed Feng-Jay closed 1 year ago

Feng-Jay commented 1 year ago

Hi, I'm Learning Java and not very familiar with Java's verison control tools(such as maven & gradle)

When I make gumtree from sourceCode, I faced a problem:

I'm using m1mac and build gum-tree v2.1.2 locally by JDK8.

Run ./gradlew build it report these:

> Task :gen.jdt:compileJava FAILED
/Users/ffengjay/Postgraduate/PLM4APR/gumtree-2.1.2/gen.jdt/src/main/java/com/github/gumtreediff/gen/jdt/AbstractJdtTreeGenerator.java:60: error: cannot access Plugin
        Map pOptions = JavaCore.getOptions();
                               ^
  bad class file: /Users/ffengjay/.gradle/caches/modules-2/files-2.1/org.eclipse.platform/org.eclipse.core.runtime/3.26.100/83c77ee0cfc948ea33f5054dda3f5c39250a7ed5/org.eclipse.core.runtime-3.26.100.jar(org/eclipse/core/runtime/Plugin.class)
    class file has wrong version 55.0, should be 52.0

It seems that it using JDT 3.26.100 rather than /gen.JDT/build.gradle's 3.16.xx. I tried to clean cache but it will still using 3.26.100's class.

By the way, it reported two lines when ./gradlew build begining:

 >>> ./gradlew clean build 

> Configure project :benchmark
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git

Is there any way fix this?

Feng-Jay commented 1 year ago

Fine, I update to GTD v3.0.0, it works fine now. 😄