No compiler is provided in this environment perhaps you are running on a jre rather than a jdk

0 votes

While working on a project on Eclipse using m2eclipse, the JDK path was set in a way on Eclipse in the manner stated below but yet, it is coming to an error. What is the solution for this?

Windows-->preferences-->installed jres--> jdk1.7.xx path

[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? 
[INFO] 1 error 
[INFO] ------------------------------------------------------------- 
[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.424s 
[INFO] Finished at: Tue Oct 29 15:21:01 IST 2013
[INFO] Final Memory: 5M/15M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler- plugin:3.1:compile (default-compile) on project TEST-WEB: Compilation failure 
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?

Feb 8 in Java by Soham
• 8,730 points
278 views

1 answer to this question.

0 votes

Once you are on your Eclipse integrated development environment, follow the respective order:-

Window > Preferences > Java > Installed JREs > and check your installed JREs. An entry with the JDK should be present. After which one must:-

  1. Click on the Execution Env as shown in the image below the answer, after which Click on OK

  2. Followed by Right-Clicking  on your Project -> Maven -> Update Project

Further on, Maven JRE will have to be altered in the given description:-

Goto Run -> Run Configurations, and then Maven Build must be chosen which is at the left side of the panel. After which, one must open a JRE tab and the Workspace default JRE option must be chosen or selected.

image

answered Feb 8 by Rahul
• 8,980 points

Related Questions In Java

0 votes
1 answer

No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK

In your Eclipse IDE, go into Window > Preferences > Java > Installed JREs > ...READ MORE

answered Jun 18, 2018 in Java by Parth
• 4,630 points
2,603 views
0 votes
2 answers
0 votes
1 answer

How to set path if java is installed in E drive or D drive rather than c

Hello, @Amazing, It doesn't really matter where you ...READ MORE

answered Sep 1, 2020 in Java by Roshni
• 10,500 points
945 views
0 votes
3 answers

Check if a String is numeric in Java

Java 8 Lambda Expression is used: String someString ...READ MORE

answered Sep 3, 2018 in Java by Daisy
• 8,120 points
2,451 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
1,563 views
+2 votes
1 answer
0 votes
1 answer
0 votes
1 answer

How to split a string in Java

By using the appropriate method, this can ...READ MORE

answered Feb 9 in Java by Rahul
• 8,980 points
27 views
webinar REGISTER FOR FREE WEBINAR X
Send OTP
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP