ghillairet / xcore-gradle-example

xcore-gradle-example
5 stars 5 forks source link

java.lang.SecurityException with gradle 4.8.1 #6

Open AresEkb opened 6 years ago

AresEkb commented 6 years ago

Hi

The example is built fine using gradle 3.1. But I get the following error with gradle 4.8.1: java.lang.SecurityException: class "org.eclipse.core.runtime.Plugin"'s signer information does not match signer information of other classes in the same package

Dependency trees (gradle dependencies) are almost identical for both gradle versions except guava versions:

Gradle 3.1 use newer version of guava:

+--- org.eclipse.xtext:org.eclipse.xtext.ecore:2.13.0
|    \--- org.eclipse.xtext:org.eclipse.xtext:2.13.0
|         +--- org.eclipse.xtext:org.eclipse.xtext.util:2.13.0
|         |    +--- org.eclipse.xtend:org.eclipse.xtend.lib:2.13.0
|         |    |    +--- org.eclipse.xtext:org.eclipse.xtext.xbase.lib:2.13.0
|         |    |    |    \--- com.google.guava:guava:[14.0,19) -> 18.0
|         |    |    \--- org.eclipse.xtend:org.eclipse.xtend.lib.macro:2.13.0
|         |    |         \--- org.eclipse.xtext:org.eclipse.xtext.xbase.lib:2.13.0 (*)
|         |    +--- log4j:log4j:1.2.16
|         |    +--- org.eclipse.emf:org.eclipse.emf.common:[2.10.1,3) -> 2.12.0
|         |    +--- org.eclipse.emf:org.eclipse.emf.ecore:[2.10.2,3) -> 2.12.0
|         |    \--- com.google.inject:guice:3.0 -> 4.0
|         |         +--- javax.inject:javax.inject:1
|         |         +--- aopalliance:aopalliance:1.0
|         |         \--- com.google.guava:guava:16.0.1 -> 18.0
|         +--- org.eclipse.xtend:org.eclipse.xtend.lib:2.13.0 (*)
|         +--- log4j:log4j:1.2.16
|         +--- org.eclipse.platform:org.eclipse.equinox.common:3.8.0
|         +--- org.eclipse.platform:org.eclipse.osgi:3.11.2
|         +--- org.eclipse.emf:org.eclipse.emf.common:[2.10.1,3) -> 2.12.0
|         +--- org.eclipse.emf:org.eclipse.emf.ecore.xmi:[2.10.2,3) -> 2.12.0
|         +--- com.google.inject:guice:3.0 -> 4.0 (*)
|         \--- org.antlr:antlr-runtime:3.2
\--- org.eclipse.emf:org.eclipse.emf.mwe2.runtime:+ -> 2.9.1.201705291010
     \--- com.google.inject:guice:3.0 -> 4.0 (*)

Gradle 4.8.1:

+--- org.eclipse.xtext:org.eclipse.xtext.ecore:2.13.0
|    \--- org.eclipse.xtext:org.eclipse.xtext:2.13.0
|         +--- org.eclipse.xtext:org.eclipse.xtext.util:2.13.0
|         |    +--- org.eclipse.xtend:org.eclipse.xtend.lib:2.13.0
|         |    |    +--- org.eclipse.xtext:org.eclipse.xtext.xbase.lib:2.13.0
|         |    |    |    \--- com.google.guava:guava:[14.0,19) -> 16.0.1
|         |    |    \--- org.eclipse.xtend:org.eclipse.xtend.lib.macro:2.13.0
|         |    |         \--- org.eclipse.xtext:org.eclipse.xtext.xbase.lib:2.13.0 (*)
|         |    +--- log4j:log4j:1.2.16
|         |    +--- org.eclipse.emf:org.eclipse.emf.common:[2.10.1,3) -> 2.12.0
|         |    +--- org.eclipse.emf:org.eclipse.emf.ecore:[2.10.2,3) -> 2.12.0
|         |    \--- com.google.inject:guice:3.0 -> 4.0
|         |         +--- javax.inject:javax.inject:1
|         |         +--- aopalliance:aopalliance:1.0
|         |         \--- com.google.guava:guava:16.0.1
|         +--- org.eclipse.xtend:org.eclipse.xtend.lib:2.13.0 (*)
|         +--- log4j:log4j:1.2.16
|         +--- org.eclipse.platform:org.eclipse.equinox.common:3.8.0
|         +--- org.eclipse.platform:org.eclipse.osgi:3.11.2
|         +--- org.eclipse.emf:org.eclipse.emf.common:[2.10.1,3) -> 2.12.0
|         +--- org.eclipse.emf:org.eclipse.emf.ecore.xmi:[2.10.2,3) -> 2.12.0
|         +--- com.google.inject:guice:3.0 -> 4.0 (*)
|         \--- org.antlr:antlr-runtime:3.2
\--- org.eclipse.emf:org.eclipse.emf.mwe2.runtime:+ -> 2.9.1.201705291010
     \--- com.google.inject:guice:3.0 -> 4.0 (*)

I added the following to build.gradle:

configurations.all {
    resolutionStrategy { 
        force 'com.google.guava:guava:18.0'
    }
}

Dependency trees are identical now. But I still get the same error with gradle 4.8.1.

Could you suggest a solution?

AresEkb commented 6 years ago

I added also a comment here: https://github.com/xtext/xtext-gradle-plugin/issues/121#issuecomment-403751958