Andreas Sewe
2017-02-17 16:39:20 UTC
Hi,
I my build, there are two versions of bundle com.google.guava: 15.0.0
and 21.0.0. Now, one of my plugins has
15.0.0 of com.google.guava (which exports the above package).
During a "mvn dependency:tree" however, Maven lists (only) Guava 21.0.0
pulls in Guava 21.0.0 transitively.
The resulting discrepancy between the OSGi world and Tycho's
approximation of the rest of the world causes other plugins, like the
InputSupplier.getInput(), but apparently the animal-sniffer-maven-plugin
is looking at the wrong version, namely Guava 21.0.0.
Is this a bug with Tycho 1.0.0? I would think so, as being able to use
non-Tycho Maven plugins like animal-sniffer-maven-plugin seems like a
huge win (and so far has worked fine).
Best wishes,
Andreas
--
Codetrails GmbH
The knowledge transfer company
Robert-Bosch-Str. 7, 64293 Darmstadt
Phone: +49-6151-276-7092
Mobile: +49-170-811-3791
http://www.codetrails.com/
Managing Director: Dr. Marcel Bruch
Handelsregister: Darmstadt HRB 91940
I my build, there are two versions of bundle com.google.guava: 15.0.0
and 21.0.0. Now, one of my plugins has
Import-Package: com.google.common.base;version="[15.0.0,16.0.0)"
in its MANIFEST.MF. During compilation, this works fine. It sees version15.0.0 of com.google.guava (which exports the above package).
During a "mvn dependency:tree" however, Maven lists (only) Guava 21.0.0
[INFO] ------------------------------------------------------------------------
[INFO] Building org.eclipse.epp.logging.aeri.ide 2.0.3-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] org.eclipse.epp.logging:org.eclipse.epp.logging.aeri.ide:eclipse-plugin:2.0.3-SNAPSHOT
[INFO] +- p2.eclipse-plugin:com.google.guava:jar:21.0.0.v20170206-1425:system
Apparently, one of org.eclipse.epp.logging.aeri.ide's own dependencies[INFO] Building org.eclipse.epp.logging.aeri.ide 2.0.3-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] org.eclipse.epp.logging:org.eclipse.epp.logging.aeri.ide:eclipse-plugin:2.0.3-SNAPSHOT
[INFO] +- p2.eclipse-plugin:com.google.guava:jar:21.0.0.v20170206-1425:system
pulls in Guava 21.0.0 transitively.
The resulting discrepancy between the OSGi world and Tycho's
approximation of the rest of the world causes other plugins, like the
[INFO] Checking unresolved references to org.codehaus.mojo.signature:java18:1.0
[ERROR] /tmp/org.eclipse.epp.logging/bundles/org.eclipse.epp.logging.aeri.ide/src/org/eclipse/epp/internal/logging/aeri/ide/utils/Zips.java:56: Undefined reference: Object com.google.common.io.OutputSupplier.getOutput()
[ERROR] /tmp/org.eclipse.epp.logging/git/org.eclipse.epp.logging/bundles/org.eclipse.epp.logging.aeri.ide/src/org/eclipse/epp/internal/logging/aeri/ide/server/json/Json.java:152: Undefined reference: Object com.google.common.io.InputSupplier.getInput()
Guava 15.0.0 contains OutputSupplier.getOutput() and[ERROR] /tmp/org.eclipse.epp.logging/bundles/org.eclipse.epp.logging.aeri.ide/src/org/eclipse/epp/internal/logging/aeri/ide/utils/Zips.java:56: Undefined reference: Object com.google.common.io.OutputSupplier.getOutput()
[ERROR] /tmp/org.eclipse.epp.logging/git/org.eclipse.epp.logging/bundles/org.eclipse.epp.logging.aeri.ide/src/org/eclipse/epp/internal/logging/aeri/ide/server/json/Json.java:152: Undefined reference: Object com.google.common.io.InputSupplier.getInput()
InputSupplier.getInput(), but apparently the animal-sniffer-maven-plugin
is looking at the wrong version, namely Guava 21.0.0.
Is this a bug with Tycho 1.0.0? I would think so, as being able to use
non-Tycho Maven plugins like animal-sniffer-maven-plugin seems like a
huge win (and so far has worked fine).
Best wishes,
Andreas
--
Codetrails GmbH
The knowledge transfer company
Robert-Bosch-Str. 7, 64293 Darmstadt
Phone: +49-6151-276-7092
Mobile: +49-170-811-3791
http://www.codetrails.com/
Managing Director: Dr. Marcel Bruch
Handelsregister: Darmstadt HRB 91940