Java sources in Eclipse on Mac OS X

Problem: Eclipse IDE does not show the sources for JRE classes on Mac OS X:

No Java JRE Sources

Solution: Download and install Java for Mac OS X Developer Package (registration required).

This will create a folder /Library/Java/JavaVirtualMachines/1.6.0_*/Contents/Home that can be added as JRE in Eclipse:

Eclipse JRE configuration

Voila:

Java JRE Sources

Ralf Ebert

Ralf Ebert is an independent software developer and trainer. He makes apps for Mac OS X and iOS and offers iOS and Git training courses for software developers.