title: No Java source on Mac OS X
body: <p>I think my JDK is broken. I am on OS X 10.6.8.</p>
  
  <p>I want to look in the sources when debugging in Eclipse, etc, but Eclipse can't find the sources, so I looked up the installed JREs and found this path with the title <code>JVM 1.6.0 (MacOS X Default)</code></p>
  
  <pre><code>/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Home
  </code></pre>
  
  <p>In Terminal I went to the directory <code>/System/Library/Frameworks/JavaVM.framework/Versions</code> and executed <code>ls -al</code>:</p>
  
  <pre><code>drwxr-xr-x  13 root  wheel  442  8 Sep 22:46 .
  drwxr-xr-x  12 root  wheel  408  8 Sep 22:46 ..
  lrwxr-xr-x   1 root  wheel    5  8 Sep 22:45 1.3 -&gt; 1.3.1
  drwxr-xr-x   3 root  wheel  102 21 Jul  2009 1.3.1
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.4 -&gt; CurrentJDK
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.4.2 -&gt; CurrentJDK
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.5 -&gt; CurrentJDK
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.5.0 -&gt; CurrentJDK
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.6 -&gt; CurrentJDK
  lrwxr-xr-x   1 root  wheel   10  8 Sep 22:45 1.6.0 -&gt; CurrentJDK
  drwxr-xr-x  10 root  wheel  340  8 Sep 22:46 A
  lrwxr-xr-x   1 root  wheel    1  8 Sep 22:45 Current -&gt; A
  lrwxr-xr-x   1 root  wheel   59  8 Sep 22:45 CurrentJDK -&gt; /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents
  </code></pre>
  
  <p>So Eclipse already has the proper JDK linked.
  Another test:</p>
  
  <pre><code>$ javac -version
  javac 1.6.0_26
  
  $ which javac
  /usr/bin/javac
  
  $ ls -al /usr/bin/ | grep javac
  lrwxr-xr-x     1 root   wheel          75  8 Sep 22:45 javac -&gt; /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/javac
  </code></pre>
  
  <p>So it all looks fine, but there is no rt.jar or src.jar Here is a screenshot:</p>
  
  <p><img src="https://i.stack.imgur.com/Gwjr3.jpg" alt="A screenshot showing the jars in the current JDK."></p>
  
  <p>So I try to reinstall it. I go to Apple's <a href="http://connect.apple.com/cgi-bin/WebObjects/MemberSite.woa/wa/downloads" rel="nofollow noreferrer">website</a> and download this package: <code>Java for Mac OS X 10.6 Update 5 Developer Package</code>, file: <code>javadeveloper_for_mac_os_x_10.6__10m3425.dmg</code>.
  The installation finished successfully, but it doesn't change anything.</p>
  
  <p>I show the last modified files on my computer, these are only some java tools, located in <code>usr/share/java/Tools</code></p>
  
  <ul>
  <li>Java VisualVM </li>
  <li>Jar Bundler </li>
  <li>Applet Launcher</li>
  </ul>
  
  <p>There still is no rt.jar or src.jar in the java home directory.</p>