New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cause: taskdef class com.sun.tools.xjc.XJCTask cannot be found #1

Closed
hygl opened this Issue Oct 20, 2011 · 2 comments

Comments

Projects
None yet
2 participants
@hygl

hygl commented Oct 20, 2011

Version 1.1-SNAPSHOT Gradle 1.0 Milestone 3

I have added jaxb-xjc as a dependecy:

dependencies {
classpath module(group: 'no.entitas', name: 'gradle-jaxb-plugin', version: '1.1-SNAPSHOT'){
dependency "com.sun.xml.bind:jaxb-xjc:2.2.4-1"
}

  • What went wrong:
    A problem occurred evaluating root project 'fiqu-ws'.
    Cause: taskdef class com.sun.tools.xjc.XJCTask cannot be found
    using the classloader AntClassLoader[]
    Cause: com.sun.tools.xjc.XJCTask
  • Try:
    Run with --info or --debug option to get more log output.
  • Exception is:
    org.gradle.api.GradleScriptException: A problem occurred evaluating root project 'fiqu-ws'.
    at org.gradle.groovy.scripts.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:51)
    at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl.apply(DefaultScriptPluginFactory.java:127)
    at org.gradle.configuration.BuildScriptProcessor.evaluate(BuildScriptProcessor.java:38)
    at org.gradle.configuration.DefaultProjectEvaluator.evaluate(DefaultProjectEvaluator.java:38)
    at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:487)
    at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:71)
    at org.gradle.configuration.ProjectEvaluationConfigurer.execute(ProjectEvaluationConfigurer.java:23)
    at org.gradle.configuration.ProjectEvaluationConfigurer.execute(ProjectEvaluationConfigurer.java:21)
    at org.gradle.configuration.DefaultBuildConfigurer$1.execute(DefaultBuildConfigurer.java:38)
    at org.gradle.configuration.DefaultBuildConfigurer$1.execute(DefaultBuildConfigurer.java:35)
    at org.gradle.api.internal.project.AbstractProject.configure(AbstractProject.java:463)
    at org.gradle.api.internal.project.AbstractProject.allprojects(AbstractProject.java:458)
    at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:35)
    at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:141)
    at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:112)
    at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:80)
    at org.gradle.launcher.RunBuildAction.execute(RunBuildAction.java:41)
    at org.gradle.launcher.RunBuildAction.execute(RunBuildAction.java:27)
    at org.gradle.launcher.ExceptionReportingAction.execute(ExceptionReportingAction.java:32)
    at org.gradle.launcher.ExceptionReportingAction.execute(ExceptionReportingAction.java:21)
    at org.gradle.launcher.CommandLineActionFactory$WithLoggingAction.execute(CommandLineActionFactory.java:219)
    at org.gradle.launcher.CommandLineActionFactory$WithLoggingAction.execute(CommandLineActionFactory.java:203)
    at org.gradle.launcher.Main.execute(Main.java:55)
    at org.gradle.launcher.Main.main(Main.java:40)
    at org.gradle.launcher.ProcessBootstrap.runNoExit(ProcessBootstrap.java:46)
    at org.gradle.launcher.ProcessBootstrap.run(ProcessBootstrap.java:28)
    at org.gradle.launcher.GradleMain.main(GradleMain.java:24)
    Caused by: : taskdef class com.sun.tools.xjc.XJCTask cannot be found
    using the classloader AntClassLoader[]
    at org.apache.tools.ant.taskdefs.Definer.addDefinition(Definer.java:622)
    at org.apache.tools.ant.taskdefs.Definer.execute(Definer.java:239)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
    at org.gradle.api.internal.project.ant.BasicAntBuilder.nodeCompleted(BasicAntBuilder.java:71)
    at org.gradle.api.internal.project.ant.BasicAntBuilder.doInvokeMethod(BasicAntBuilder.java:86)
    at org.gradle.api.internal.project.DefaultAntBuilder.super$3$invokeMethod(DefaultAntBuilder.groovy)
    at org.gradle.api.internal.project.DefaultAntBuilder.invokeMethod(DefaultAntBuilder.groovy:37)
    at no.entitas.gradle.JaxbPlugin$_createJaxbTask_closure6.doCall(JaxbPlugin.groovy:67)
    at org.gradle.util.ConfigureUtil.configure(ConfigureUtil.java:61)
    at org.gradle.util.ConfigureUtil.configure(ConfigureUtil.java:31)
    at org.gradle.api.internal.AbstractTask.configure(AbstractTask.java:398)
    at org.gradle.api.internal.project.AbstractProject.task(AbstractProject.java:929)
    at org.gradle.api.Project$task$0.call(Unknown Source)
    at no.entitas.gradle.JaxbPlugin.createJaxbTask(JaxbPlugin.groovy:63)
    at no.entitas.gradle.JaxbPlugin.this$2$createJaxbTask(JaxbPlugin.groovy)
    at no.entitas.gradle.JaxbPlugin$this$2$createJaxbTask.callCurrent(Unknown Source)
    at no.entitas.gradle.JaxbPlugin.injectJaxbTask(JaxbPlugin.groovy:48)
    at no.entitas.gradle.JaxbPlugin.this$2$injectJaxbTask(JaxbPlugin.groovy)
    at no.entitas.gradle.JaxbPlugin$this$2$injectJaxbTask.callCurrent(Unknown Source)
    at no.entitas.gradle.JaxbPlugin.apply(JaxbPlugin.groovy:19)
    at no.entitas.gradle.JaxbPlugin.apply(JaxbPlugin.groovy)
    at org.gradle.api.internal.plugins.DefaultProjectsPluginContainer.providePlugin(DefaultProjectsPluginContainer.java:103)
    at org.gradle.api.internal.plugins.DefaultProjectsPluginContainer.addPluginInternal(DefaultProjectsPluginContainer.java:67)
    at org.gradle.api.internal.plugins.DefaultProjectsPluginContainer.apply(DefaultProjectsPluginContainer.java:37)
    at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.applyPlugin(DefaultObjectConfigurationAction.java:101)
    at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.access$200(DefaultObjectConfigurationAction.java:32)
    at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction$3.run(DefaultObjectConfigurationAction.java:72)
    at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.execute(DefaultObjectConfigurationAction.java:114)
    at org.gradle.api.internal.project.AbstractProject.apply(AbstractProject.java:854)
    at org.gradle.api.Project$apply.call(Unknown Source)
    at org.gradle.api.internal.project.ProjectScript.apply(ProjectScript.groovy:35)
    at org.gradle.api.Script$apply.callCurrent(Unknown Source)
    at build_793i7ponmfq6pjb8167hanitg1.run(D:\Projekte\fiqu-ws\build.gradle:3)
    at org.gradle.groovy.scripts.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:49)
    ... 26 more
    Caused by: java.lang.ClassNotFoundException: com.sun.tools.xjc.XJCTask
    at org.apache.tools.ant.AntClassLoader.findClassInComponents(AntClassLoader.java:1361)
    at org.apache.tools.ant.AntClassLoader.findClass(AntClassLoader.java:1311)
    at org.apache.tools.ant.AntClassLoader.loadClass(AntClassLoader.java:1064)
    at org.apache.tools.ant.taskdefs.Definer.addDefinition(Definer.java:594)
    ... 60 more

@ghost ghost assigned stigkj Oct 20, 2011

@stigkj

This comment has been minimized.

Show comment
Hide comment
@stigkj

stigkj Oct 20, 2011

Collaborator

You do not need to add the jaxb-xjc dependency as that is included in the plugin. Or do you need that specific version?

Collaborator

stigkj commented Oct 20, 2011

You do not need to add the jaxb-xjc dependency as that is included in the plugin. Or do you need that specific version?

@hygl

This comment has been minimized.

Show comment
Hide comment
@hygl

hygl Oct 20, 2011

No, I did not get the jaxb-xjc jar at all before. However It works form me now, can not reproduce the bug.

hygl commented Oct 20, 2011

No, I did not get the jaxb-xjc jar at all before. However It works form me now, can not reproduce the bug.

@hygl hygl closed this Oct 20, 2011

stianh pushed a commit that referenced this issue Jul 24, 2014

Merge pull request #1 from bitdeli-chef/master
Add a Bitdeli Badge to README
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment