title: Dagger 2 does not generate component
body: <p>I totally exhausted with Dagger 2 in <strong>non-Android</strong> app (IDE is IntelliJ IDEA).</p>
  
  <p><strong>build.gradle</strong></p>
  
  <pre><code>buildscript {
      repositories {
          maven {
              url "https://plugins.gradle.org/m2/"
          }
      }
      dependencies {
          classpath "net.ltgt.gradle:gradle-apt-plugin:0.9"
      }
  }
  
  apply plugin: 'java'
  apply plugin: 'net.ltgt.apt'
  
  dependencies {
      compile 'com.google.dagger:dagger:2.8'
      apt 'com.google.dagger:dagger-compiler:2.8'
      compileOnly 'javax.annotation:jsr250-api:1.0'
  }
  </code></pre>
  
  <p><strong>Component</strong></p>
  
  <pre><code>@Component(modules = {MyModule.class}) public interface MyComponent {}
  </code></pre>
  
  <p><strong>Module</strong></p>
  
  <pre><code>@Module class MyModule {}
  </code></pre>
  
  <p><strong>Main</strong></p>
  
  <pre><code>DaggerMyComponent component = DaggerMyComponent.builder().build();
  </code></pre>
  
  <p>Compiler says </p>
  
  <blockquote>
    <p>cannot find symbol DaggerMyComponent</p>
  </blockquote>
  
  <p>Absolutely have no more ideas what could be wrong :(</p>
  
  <p>By the way, if I run <code>gradlew clean build --refresh-dependencies</code>, there is no error, everything fine!</p>
  
  <p>But as only I use 'Rebuild project' in IDE - error again. Possibly IDEA bug (time to go back to Eclipse)?</p>
  
  <p>And yes, I have added directory with generated classes as a content root, so IDE can see <code>DaggerMyComponent</code>.</p>