SerCeMan / jnr-fuse

FUSE implementation in Java using Java Native Runtime (JNR)
MIT License
370 stars 88 forks source link

Build failure #12

Closed fantom-x closed 8 years ago

fantom-x commented 8 years ago

Hi, trying to build with gradle and getting the failure below (I only provided the bottom two stack frames). I am obviously doing something wrong her, but can not figure out what it is exactly.Thanks in advance.

gradle -v

------------------------------------------------------------
Gradle 2.13
------------------------------------------------------------

Build time:   2016-04-25 04:10:10 UTC
Build number: none
Revision:     3b427b1481e46232107303c90be7b05079b05b1c

Groovy:       2.4.4
Ant:          Apache Ant(TM) version 1.9.6 compiled on June 29 2015
JVM:          1.8.0_65 (Oracle Corporation 25.65-b01)
OS:           Linux 4.1.19-v7+ arm
11:25:12.323 [ERROR] [org.gradle.BuildExceptionReporter] 
11:25:12.325 [ERROR] [org.gradle.BuildExceptionReporter] FAILURE: Build failed with an exception.
11:25:12.327 [ERROR] [org.gradle.BuildExceptionReporter] 
11:25:12.328 [ERROR] [org.gradle.BuildExceptionReporter] * Where:
11:25:12.329 [ERROR] [org.gradle.BuildExceptionReporter] Build file '/root/jnr-fuse/build.gradle' line: 2
11:25:12.331 [ERROR] [org.gradle.BuildExceptionReporter] 
11:25:12.333 [ERROR] [org.gradle.BuildExceptionReporter] * What went wrong:
11:25:12.334 [ERROR] [org.gradle.BuildExceptionReporter] An exception occurred applying plugin request [id: 'java']
11:25:12.335 [ERROR] [org.gradle.BuildExceptionReporter] > Failed to apply plugin [class 'com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin']
11:25:12.337 [ERROR] [org.gradle.BuildExceptionReporter]    > Could not create task of type 'ShadowJar'.
11:25:12.338 [ERROR] [org.gradle.BuildExceptionReporter] 
11:25:12.339 [ERROR] [org.gradle.BuildExceptionReporter] * Try:
11:25:12.340 [ERROR] [org.gradle.BuildExceptionReporter] Run with --stacktrace option to get the stack trace. 
11:25:12.343 [LIFECYCLE] [org.gradle.BuildResultLogger] 
11:25:12.344 [LIFECYCLE] [org.gradle.BuildResultLogger] BUILD FAILED
11:25:12.346 [LIFECYCLE] [org.gradle.BuildResultLogger] 
11:25:12.347 [LIFECYCLE] [org.gradle.BuildResultLogger] Total time: 14.043 secs
Caused by: org.gradle.api.tasks.TaskInstantiationException: Could not create task of type 'ShadowJar'.
    at org.gradle.api.internal.project.taskfactory.TaskFactory$1.call(TaskFactory.java:123)
    at org.gradle.api.internal.project.taskfactory.TaskFactory$1.call(TaskFactory.java:118)
    at org.gradle.api.internal.AbstractTask.injectIntoNewInstance(AbstractTask.java:143)
    at org.gradle.api.internal.project.taskfactory.TaskFactory.create(TaskFactory.java:118)
    at org.gradle.api.internal.project.taskfactory.TaskFactory.createTask(TaskFactory.java:77)
    at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory.createTask(AnnotationProcessingTaskFactory.java:101)
    at org.gradle.api.internal.project.taskfactory.DependencyAutoWireTaskFactory.createTask(DependencyAutoWireTaskFactory.java:39)
    at org.gradle.api.internal.tasks.DefaultTaskContainer.create(DefaultTaskContainer.java:62)
    at org.gradle.api.internal.tasks.DefaultTaskContainer.create(DefaultTaskContainer.java:97)
    at org.gradle.api.tasks.TaskContainer$create.call(Unknown Source)
    at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.configureShadowTask(ShadowJavaPlugin.groovy:40)
    at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.apply(ShadowJavaPlugin.groovy:35)
    at com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.apply(ShadowJavaPlugin.groovy)
    at org.gradle.api.internal.plugins.ImperativeOnlyPluginApplicator.applyImperative(ImperativeOnlyPluginApplicator.java:35)
    at org.gradle.api.internal.plugins.RuleBasedPluginApplicator.applyImperative(RuleBasedPluginApplicator.java:43)
    at org.gradle.api.internal.plugins.DefaultPluginManager.doApply(DefaultPluginManager.java:137)
    ... 60 more
Caused by: java.lang.NoSuchMethodError: org.gradle.api.java.archives.internal.DefaultManifest.<init>(Lorg/gradle/api/internal/file/FileResolver;)V
    at com.github.jengelman.gradle.plugins.shadow.tasks.DefaultInheritManifest.<init>(DefaultInheritManifest.groovy:15)
    at com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar.<init>(ShadowJar.java:44)
    at com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar_Decorated.<init>(Unknown Source)
    at org.gradle.api.internal.DependencyInjectingInstantiator.newInstance(DependencyInjectingInstantiator.java:48)
    at org.gradle.api.internal.ClassGeneratorBackedInstantiator.newInstance(ClassGeneratorBackedInstantiator.java:36)
    at org.gradle.api.internal.project.taskfactory.TaskFactory$1.call(TaskFactory.java:121)
    ... 75 more
fantom-x commented 8 years ago

I have downgraded gradle from 2.13 (the latest) to 2.2 and now everything is working on the command line. Eclipse Mars worked fine all the time, because it comes with gradle 2.2...

SerCeMan commented 8 years ago

It seems like a problem with shadow plugin. I'll fix it soon.

ghost commented 8 years ago

How about using gradlew?

SerCeMan commented 8 years ago

@ensirius With gradlew everything would be ok, but it is always a good idea to use latest gradle

ghost commented 8 years ago

If i correctly remember, to fix this, just update shadow plugin version to 1.2.3

SerCeMan commented 8 years ago

updated to gradle 3.1