Eclipse ant component appears unable to find a javac compiler Solution

Source: Internet
Author: User

The solution is in the opinion of a foreigner's blog. Remember my blog for your convenience.

The author explains that ant cannot be used with JRE, but JDK must be used as the runtime JRE. But this does not seem to be the real reason, but this method can solve the problem, the solution is as follows:

Open the menu: Run -- external tool -- External tools...

Open the JRE page on the right and select JDK in separate JRE:. If this option is not available, click installed jres... --- click Add --- to add a JDK entry.

The specific method is:
Enter JRE name: (random) JDK
Find the JDK installation path and enter JRE home directory.
Exit

Go back to the JRE page of external tools... and click exit.

So far, my problem is solved, but write this articleArticleI found that even now, changing the runtime JRE back to JRE does not seem to be a problem, so I personally think it may be a bug of ecplise, before using ant for the first time, you may need to manually specify a runtime JRE. Changing JRE to JDK just completes this step.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.