JDK source files on Mac

Source: Internet
Author: User

I have been studying GWT these two days, using a Mac notebook.

As a result, JDK source files are required for GWT compilation, but SRC is not found after half a day. Jar

 

After searching online for a long time, I finally found a solution.

1. Download the Java developer package from connect.apple.com. Then install.

2. Run the find command to find SRC. jar.

Find/library/Java/javavirtualmachines/-name SRC. Jar

3. This jar can be found in terminal, but it cannot be referenced in eclipse. After reading the reference link, you can create a link for this jar.

CD/system/library/Java/javavirtualmachines/1.6.0.jdk/contents/home/

Sudo mkdir SRC

CD SRC

Sudo ln-S/library/Java/javavirtualmachines/1.6.0 _ 22-b04-307.jdk/contents/home/src. Jar

In this way, you can reference this jar in eclipse.

 

Finally, GWT can be compiled normally.

 

 

Reference: http://stackoverflow.com/questions/4011002/java-eclipse-on-macosx-where-is-the-src-zip

 

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.