diff --git a/buildSrc/src/main/kotlin/android/support/DiffAndDocs.kt b/buildSrc/src/main/kotlin/android/support/DiffAndDocs.kt
index 9f0e402..b21d6dd 100644
--- a/buildSrc/src/main/kotlin/android/support/DiffAndDocs.kt
+++ b/buildSrc/src/main/kotlin/android/support/DiffAndDocs.kt
@@ -163,7 +163,6 @@
             }
         }
 
-
 // Generates API files
 private fun createGenerateApiTask(project: Project, docletpathParam: Collection<File>) =
         project.tasks.createWithConfig("generateApi", DoclavaTask::class.java) {
@@ -285,7 +284,7 @@
 
             if (toApi != null) {
                 // Use an explicit API file.
-                inputApiFile = File(project.projectDir, "api/${toApi}.txt")
+                inputApiFile = File(project.projectDir, "api/$toApi.txt")
             } else {
                 // Use the current API file (e.g. current.txt).
                 inputApiFile = generateApi.apiFile
@@ -296,7 +295,6 @@
                     "release/${stripExtension(inputApiFile.name)}.xml")
         }
 
-
 /**
  * Generates API diffs.
  * <p>
@@ -352,7 +350,6 @@
             dependsOn(oldApiTask, newApiTask, jdiffConfig)
         }
 
-
 // Generates a distribution artifact for online docs.
 private fun createDistDocsTask(project: Project, generateDocs: DoclavaTask) =
         project.tasks.createWithConfig("distDocs", Zip::class.java) {
@@ -577,15 +574,22 @@
 
     root.subprojects { subProject ->
         subProject.afterEvaluate { project ->
-            if (project.hasProperty("noDocs") && (project.properties["noDocs"] as Boolean)) {
-                project.logger.warn("Project $project.name specified noDocs, ignoring API tasks.")
-                return@afterEvaluate
+            val extension = if (project.hasProperty("supportLibrary")) {
+                project.properties["supportLibrary"] as SupportLibraryExtension
+            } else {
+                null
             }
-            if (project.hasProperty("supportLibrary")
-                    && !(project.properties["supportLibrary"] as SupportLibraryExtension).publish) {
+            if (extension == null || !extension.publish) {
                 project.logger.warn("Project ${project.name} is not published, ignoring API tasks.")
                 return@afterEvaluate
             }
+
+            if (!extension.generateDocs) {
+                project.logger.warn("Project ${project.name} specified generateDocs = false, " +
+                        "ignoring API tasks.")
+                return@afterEvaluate
+            }
+
             val library = project.extensions.findByType(LibraryExtension::class.java)
             if (library != null) {
                 library.libraryVariants.all { variant ->
@@ -609,7 +613,7 @@
                 val compileJava = project.properties["compileJava"] as JavaCompile
                 registerJavaProjectForDocsTask(generateDocsTask, compileJava)
                 if (!hasApiFolder(project)) {
-                    project.logger.warn("Project $project.name doesn't have an api folder, " +
+                    project.logger.warn("Project ${project.name} doesn't have an api folder, " +
                             "ignoring API tasks.")
                     return@afterEvaluate
                 }
@@ -625,15 +629,15 @@
     }
 }
 
-
 private fun sdkApiFile(project: Project) = File(project.docsDir(), "release/sdk_current.txt")
 private fun removedSdkApiFile(project: Project) = File(project.docsDir(), "release/sdk_removed.txt")
 
 private fun TaskContainer.createWithConfig(name: String, config: Task.() -> Unit) =
         create(name) { task -> task.config() }
 
-private fun <T : Task> TaskContainer.createWithConfig(name: String, taskClass: Class<T>,
-                                                      config: T.() -> Unit) =
+private fun <T : Task> TaskContainer.createWithConfig(
+        name: String, taskClass: Class<T>,
+        config: T.() -> Unit) =
         create(name, taskClass) { task -> task.config() }
 
 // Nasty part. Get rid of that eventually!
@@ -649,7 +653,6 @@
 
 private fun Project.androidApiTxt() = properties["androidApiTxt"] as? File
 
-
 private fun Project.docsDac() = properties["docsDac"] as DacOptions
 
 private fun Project.processProperty(name: String) =
diff --git a/buildSrc/src/main/kotlin/android/support/SupportLibraryExtension.kt b/buildSrc/src/main/kotlin/android/support/SupportLibraryExtension.kt
index 088e169..d5519c7 100644
--- a/buildSrc/src/main/kotlin/android/support/SupportLibraryExtension.kt
+++ b/buildSrc/src/main/kotlin/android/support/SupportLibraryExtension.kt
@@ -34,6 +34,13 @@
     var java8Library = false
     var legacySourceLocation = false
     var publish = false
+    /**
+     * This flag works only if publish flag is "true".
+     * It is useful for modules that are used for tooling. For example room annotation
+     * processor module is published, but we don't want to expose any docs, because we don't
+     * support using it as a library.
+     */
+    var generateDocs = true
 
     fun license(closure: Closure<*>): License {
         val license = project.configure(License(), closure) as License
@@ -47,7 +54,8 @@
 
     companion object {
         @JvmField
-        val ARCHITECTURE_URL = "https://developer.android.com/topic/libraries/architecture/index.html"
+        val ARCHITECTURE_URL
+                = "https://developer.android.com/topic/libraries/architecture/index.html"
         @JvmField
         val SUPPORT_URL = "http://developer.android.com/tools/extras/support-library.html"
     }
diff --git a/lifecycle/integration-tests/testapp/build.gradle b/lifecycle/integration-tests/testapp/build.gradle
index 19d556b..9f970a5 100644
--- a/lifecycle/integration-tests/testapp/build.gradle
+++ b/lifecycle/integration-tests/testapp/build.gradle
@@ -18,8 +18,6 @@
 
 apply plugin: 'com.android.application'
 
-project.ext.noDocs = true
-
 android {
     compileSdkVersion tools.current_sdk
     buildToolsVersion tools.build_tools_version
diff --git a/paging/integration-tests/testapp/build.gradle b/paging/integration-tests/testapp/build.gradle
index 91312a3..99c2ef6 100644
--- a/paging/integration-tests/testapp/build.gradle
+++ b/paging/integration-tests/testapp/build.gradle
@@ -15,8 +15,6 @@
  */
 apply plugin: 'com.android.application'
 
-project.ext.noDocs = true
-
 android {
     compileSdkVersion tools.current_sdk
     buildToolsVersion tools.build_tools_version
diff --git a/room/compiler/build.gradle b/room/compiler/build.gradle
index 2b35032..57ff63f 100644
--- a/room/compiler/build.gradle
+++ b/room/compiler/build.gradle
@@ -27,7 +27,6 @@
     test.java.srcDirs += 'src/tests/kotlin'
     main.java.srcDirs += antlrOut
 }
-project.ext.noDocs = true
 
 // Temporary hack to stop AS to adding two guavas into test's classpath
 configurations.all {
@@ -80,6 +79,7 @@
 supportLibrary {
     name = "Android Room Compiler"
     publish = true
+    generateDocs = false
     mavenVersion = LibraryVersions.ROOM
     mavenGroup = LibraryGroups.ROOM
     inceptionYear = "2017"
diff --git a/room/integration-tests/kotlintestapp/build.gradle b/room/integration-tests/kotlintestapp/build.gradle
index da8116b..f444018 100644
--- a/room/integration-tests/kotlintestapp/build.gradle
+++ b/room/integration-tests/kotlintestapp/build.gradle
@@ -20,8 +20,6 @@
 apply plugin: 'kotlin-kapt'
 apply plugin: 'kotlin-android'
 
-project.ext.noDocs = true
-
 android {
     compileSdkVersion tools.current_sdk
     buildToolsVersion tools.build_tools_version
diff --git a/room/integration-tests/testapp/build.gradle b/room/integration-tests/testapp/build.gradle
index d4d4893..d1da195 100644
--- a/room/integration-tests/testapp/build.gradle
+++ b/room/integration-tests/testapp/build.gradle
@@ -18,8 +18,6 @@
 
 apply plugin: 'com.android.application'
 
-project.ext.noDocs = true
-
 android {
     compileSdkVersion tools.current_sdk
     buildToolsVersion tools.build_tools_version
