[maven-dependency-tree] 01/01: Fixed a build failure with Maven 3.1+ (Closes: #795142)
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Tue Sep 8 09:48:33 UTC 2015
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to branch master
in repository maven-dependency-tree.
commit 50283eb130d0823c000429d8174363acd494b149
Author: Emmanuel Bourg <ebourg at apache.org>
Date: Tue Sep 8 11:48:17 2015 +0200
Fixed a build failure with Maven 3.1+ (Closes: #795142)
---
debian/changelog | 7 ++++
debian/control | 2 +-
debian/maven.rules | 1 +
debian/patches/01-maven3-compatibility.patch | 62 ++++++++++++++++++++++++++++
debian/patches/series | 1 +
5 files changed, 72 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 9b873f8..caac3e3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+maven-dependency-tree (2.0-2) unstable; urgency=medium
+
+ * Team upload.
+ * Fixed a build failure with Maven 3.1+ (Closes: #795142)
+
+ -- Emmanuel Bourg <ebourg at apache.org> Tue, 08 Sep 2015 11:11:17 +0200
+
maven-dependency-tree (2.0-1) unstable; urgency=medium
* Team upload.
diff --git a/debian/control b/debian/control
index ab95895..e4e807b 100644
--- a/debian/control
+++ b/debian/control
@@ -10,7 +10,7 @@ Build-Depends-Indep: default-jdk-doc,
libjmock-java,
libmaven-javadoc-plugin-java,
libmaven-plugin-testing-java,
- maven,
+ libmaven3-core-java,
libplexus-maven-plugin-java
Standards-Version: 3.9.6
Vcs-Git: git://anonscm.debian.org/pkg-java/maven-dependency-tree.git
diff --git a/debian/maven.rules b/debian/maven.rules
index fb3e9d9..e3e3223 100644
--- a/debian/maven.rules
+++ b/debian/maven.rules
@@ -22,3 +22,4 @@ s/org.apache.maven.shared/org.apache.maven.plugin-testing/ maven-plugin-testing
s/org.apache.maven.shared/org.apache.maven.plugin-testing/ maven-plugin-testing-harness * s/.*/debian/ * *
s/org.apache.maven.shared/org.apache.maven.plugin-testing/ maven-test-tools * s/.*/debian/ * *
org.apache.maven maven-core * s/.*/3.x/ * *
+s/org.sonatype.aether/org.eclipse.aether/ aether-api * s/.*/debian/ * *
diff --git a/debian/patches/01-maven3-compatibility.patch b/debian/patches/01-maven3-compatibility.patch
new file mode 100644
index 0000000..8ae0f22
--- /dev/null
+++ b/debian/patches/01-maven3-compatibility.patch
@@ -0,0 +1,62 @@
+Description: Fix the compatibility with Maven 3.1
+Author: Emmanuel Bourg <ebourg at apache.org>
+Forwarded: not-needed
+--- a/src/main/java/org/apache/maven/shared/dependency/graph/internal/Maven3DependencyGraphBuilder.java
++++ b/src/main/java/org/apache/maven/shared/dependency/graph/internal/Maven3DependencyGraphBuilder.java
+@@ -40,8 +40,8 @@
+ import org.apache.maven.shared.dependency.graph.DependencyNode;
+ import org.codehaus.plexus.component.annotations.Component;
+ import org.codehaus.plexus.component.annotations.Requirement;
+-import org.sonatype.aether.graph.Dependency;
+-import org.sonatype.aether.version.VersionConstraint;
++import org.eclipse.aether.graph.Dependency;
++import org.eclipse.aether.version.VersionConstraint;
+
+ /**
+ * Wrapper around Maven 3 dependency resolver.
+@@ -101,7 +101,7 @@
+
+ private Artifact getDependencyArtifact( Dependency dep )
+ {
+- org.sonatype.aether.artifact.Artifact artifact = dep.getArtifact();
++ org.eclipse.aether.artifact.Artifact artifact = dep.getArtifact();
+
+ return factory.createDependencyArtifact( artifact.getGroupId(), artifact.getArtifactId(),
+ VersionRange.createFromVersion( artifact.getVersion() ),
+@@ -109,15 +109,15 @@
+ dep.isOptional() );
+ }
+
+- private DependencyNode buildDependencyNode( DependencyNode parent, org.sonatype.aether.graph.DependencyNode node,
++ private DependencyNode buildDependencyNode( DependencyNode parent, org.eclipse.aether.graph.DependencyNode node,
+ Artifact artifact, ArtifactFilter filter )
+ {
+ DefaultDependencyNode current =
+- new DefaultDependencyNode( parent, artifact, node.getPremanagedVersion(), node.getPremanagedScope(),
++ new DefaultDependencyNode( parent, artifact, null, null,
+ getVersionSelectedFromRange( node.getVersionConstraint() ) );
+
+ List<DependencyNode> nodes = new ArrayList<DependencyNode>( node.getChildren().size() );
+- for ( org.sonatype.aether.graph.DependencyNode child : node.getChildren() )
++ for ( org.eclipse.aether.graph.DependencyNode child : node.getChildren() )
+ {
+ Artifact childArtifact = getDependencyArtifact( child.getDependency() );
+
+@@ -139,16 +139,6 @@
+ return null;
+ }
+
+- StringBuilder sb = new StringBuilder();
+- for ( org.sonatype.aether.version.VersionRange range : constraint.getRanges() )
+- {
+- if ( sb.length() > 0 )
+- {
+- sb.append( ',' );
+- }
+- sb.append( range );
+- }
+-
+- return sb.toString();
++ return constraint.getRange().toString();
+ }
+ }
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..d1bb152
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+01-maven3-compatibility.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/maven-dependency-tree.git
More information about the pkg-java-commits
mailing list