title: IntelliJ IDEA Buildtools 24.0.2 requires Java 1.8 or above. Current JDK version is 1.7
body: <p>After trying to build my project in Mac OS X El Capitan I've got this error:</p>
  <blockquote>
  <p>Error:Gradle: A problem occurred configuring project ':app'.
  Buildtools 24.0.2 requires Java 1.8 or above.  Current JDK version is 1.7.</p>
  </blockquote>
  <p>I have project with <code>build.gradle</code> section like this:</p>
  <pre><code>android {
      compileOptions {
          sourceCompatibility JavaVersion.VERSION_1_8
          targetCompatibility JavaVersion.VERSION_1_8
  }
  </code></pre>
  <p>Also:</p>
  <blockquote>
  <p>Project SDK 1.8.0_101</p>
  <p>App Module: android sdk 24, jdk 1.8,</p>
  <p>Root Module: android sdk 24, jdk 1.8</p>
  <p>compileSdkVersion 24</p>
  <p>buildToolsVersion '24.0.2'</p>
  <p>minSdkVersion 16</p>
  <p>targetSdkVersion 24</p>
  <p>retrolambda</p>
  </blockquote>
  <p>P.S.: I successfully built this project from command line.</p>