title: Maven not recognizing javac in my Ubuntu installation
body: <p>I have gotten this error:</p>
  
  <pre><code>Compilation failure
  Unable to locate the Javac Compiler in:
    /usr/lib/jvm/java-7-openjdk-amd64/jre/../lib/tools.jar
  Please ensure you are using JDK 1.4 or above and
  not a JRE (the com.sun.tools.javac.Main class is required).
  In most cases you can change the location of your Java
  installation by setting the JAVA_HOME environment variable.
  </code></pre>
  
  <p>Now I have set some info in my <code>.bashrc</code> file like so: <code>export PATH=$PATH:/usr/lib/jvm/java-6-openjdk/bin</code>. I also did it in my /etc/profile file. But it still fails. But I am noticing that the above error is still going into <code>jre</code> instead of <code>jvm</code>. I don't really understand why its doing that. When I do <code>which javac</code>, it directs me to <code>/usr/bin/javac</code>. What exactly is that file? It seems Ubuntu defaults to JRE rather than the SDK. Either way I am confused as to how to fix this. Any help would be appreciated!</p>