Unable to perform Maven Build project in Eclipse | Community
Skip to main content
Level 4
May 11, 2020
Solved

Unable to perform Maven Build project in Eclipse

  • May 11, 2020
  • 2 replies
  • 7965 views

Hi,

 

Eclipse Version: Oxygen.3a Release (4.7.3a)
Build id: 20180405-1200

 

I am unable to perform Maven build via Eclipse getting below error

 

INFO] --- maven-clean-plugin:3.0.0:clean (default-clean) @ aem-guides-demo ---
[INFO]
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven) @ aem-guides-demo ---
[WARNING] Rule 0: org.apache.maven.plugins.enforcer.RequireMavenVersion failed with message:
Detected Maven Version: 3.2.1 is not in the allowed range [3.6.2,).
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] aem-guides-demo ................................... FAILURE [ 4.821 s]
[INFO] DEMO Sites Project - Core ......................... SKIPPED
[INFO] DEMO Sites Project - UI apps ...................... SKIPPED
[INFO] DEMO Sites Project - UI content ................... SKIPPED
[INFO] DEMO Sites Project - Integration Tests Bundles .... SKIPPED
[INFO] DEMO Sites Project - Integration Tests Launcher ... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] -----------------------------------------------------------------

 

 

Pom.xml :

 

 

Even i tried to change the configuration to use MVN home dir

 

, then i am getting below error in console 

-Dmaven.multiModuleProjectDirectory system property is not set.

 

also if i try to update m2e publish , i am getting below error

 
 

 
 

 

 

 

 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by sonuk85184451

 

Issue got fixed after setting the 

 

-Dmaven.multiModuleProjectDirectory system property for JRE and JDK

 

 
 

 

 

 

 

2 replies

ArpitVarshney
Community Advisor
Community Advisor
May 11, 2020

Hi @sonuk85184451 

 

Your eclipse is detecting the maven version as 3.2.1 only.

Could you please verify the maven version using the command mvn -version and make sure the same version is set in an environment variable as well.If it is returning 3.2.1 then set the version which is allowed in the range in the allowed range [3.6.2,)

 

Also, give a try to build your project via the normal command prompt.

 

Regards,

Arpit

 

Level 4
May 11, 2020

Thank You for responding , @arpitvarshney 

I am using Maven version 3.6.2 and able to build Maven project from command prompt successfully 

 

 

but when i am trying the same from eclipse its giving me error. let me know should i still install Maven 3.2.1 and configure Maven Var to 3.2.1 ?

sonuk85184451AuthorAccepted solution
Level 4
May 16, 2020

 

Issue got fixed after setting the 

 

-Dmaven.multiModuleProjectDirectory system property for JRE and JDK