Itiviti / gradle-ikvm-plugin

Gradle plugin for IKVM artifact compilation
Apache License 2.0
14 stars 11 forks source link

Plugin throws exception when running. #11

Closed Vad1mo closed 9 years ago

Vad1mo commented 9 years ago

When running this plugin I get this exception:

Caused by: java.lang.NoClassDefFoundError: org/apache/commons/lang/StringUtils
    at com.ullink.Ikvm.getCompileConfigurationName(Ikvm.groovy:58)
    at com.ullink.Ikvm_Decorated.getCompileConfigurationName(Unknown Source)
    at com.ullink.Ikvm.<init>(Ikvm.groovy:49)
    at com.ullink.Ikvm_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:124)
    ... 62 more
Caused by: java.lang.ClassNotFoundException: org.apache.commons.lang.StringUtils
    ... 69 more

This is because you have a compile dependency to org.apache.commons:commons-lang3 but you are using StringUtils from commons-lang2. So your plugin can only run if there is commons lang 2 on the Classpath.

FYI: The signature is org.apache.commons.lang3.StringUtils or org.apache.commons.lang.StringUtils for commons-lang version 2