Author: jvanzyl
Date: Tue Jun 2 22:53:47 2009
New Revision: 781202
URL: http://svn.apache.org/viewvc?rev=781202&view=rev
Log:
o moved the RuntimeInformation component to the compat package. The
maven-eclipse-plugin is currently using it. But for building your own projects
the enforcer plugin is more appropriate for making sure the version intended
for the project's use is being used.
Modified:
maven/components/trunk/maven-core/src/main/java/org/apache/maven/DefaultMaven.java
Modified:
maven/components/trunk/maven-core/src/main/java/org/apache/maven/DefaultMaven.java
URL:
http://svn.apache.org/viewvc/maven/components/trunk/maven-core/src/main/java/org/apache/maven/DefaultMaven.java?rev=781202&r1=781201&r2=781202&view=diff
==============================================================================
---
maven/components/trunk/maven-core/src/main/java/org/apache/maven/DefaultMaven.java
(original)
+++
maven/components/trunk/maven-core/src/main/java/org/apache/maven/DefaultMaven.java
Tue Jun 2 22:53:47 2009
@@ -20,7 +20,6 @@
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
-import java.util.Collections;
import java.util.Date;
import java.util.HashMap;
import java.util.LinkedHashMap;
@@ -28,7 +27,6 @@
import java.util.Map;
import org.apache.maven.artifact.ArtifactUtils;
-import org.apache.maven.artifact.versioning.DefaultArtifactVersion;
import org.apache.maven.exception.DefaultExceptionHandler;
import org.apache.maven.exception.ExceptionHandler;
import org.apache.maven.exception.ExceptionSummary;
@@ -38,7 +36,6 @@
import org.apache.maven.execution.MavenExecutionResult;
import org.apache.maven.execution.MavenSession;
import org.apache.maven.execution.ProjectSorter;
-import org.apache.maven.execution.RuntimeInformation;
import org.apache.maven.lifecycle.LifecycleExecutor;
import org.apache.maven.project.MavenProject;
import org.apache.maven.project.ProjectBuilder;
@@ -66,9 +63,6 @@
@Requirement
protected PlexusContainer container;
-
- @Requirement
- protected RuntimeInformation runtimeInformation;
public List<String> getLifecyclePhases()
{
@@ -203,16 +197,6 @@
{
MavenProject project = projectBuilder.build( file,
request.getProjectBuildingRequest() );
- if ( ( project.getPrerequisites() != null ) && (
project.getPrerequisites().getMaven() != null ) )
- {
- DefaultArtifactVersion version = new DefaultArtifactVersion(
project.getPrerequisites().getMaven() );
-
- if (
runtimeInformation.getApplicationInformation().getVersion().compareTo( version
) < 0 )
- {
- throw new MavenExecutionException( "Unable to build
project '" + file + "; it requires Maven version " + version.toString(), file );
- }
- }
-
if ( ( project.getModules() != null ) &&
!project.getModules().isEmpty() && request.isRecursive() )
{
File basedir = file.getParentFile();