Mark ab/7061308 as merged in stage.

Bug: 180401296
Merged-In: I7a7d0a98c4afc0964d0f6d2324c5b04d26ce466e
Change-Id: I7ca8d94e1ab6f9b926225942307416953445a879
diff --git a/Android.bp b/Android.bp
index 0fa5a64..d86573e 100644
--- a/Android.bp
+++ b/Android.bp
@@ -14,6 +14,29 @@
 //
 //
 
+package {
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
+// Added automatically by a large-scale-change
+//
+// large-scale-change included anything that looked like it might be a license
+// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc.
+//
+// Please consider removing redundant or irrelevant files from 'license_text:'.
+// See: http://go/android-license-faq
+license {
+    name: "external_grpc-grpc-java_license",
+    visibility: [":__subpackages__"],
+    license_kinds: [
+        "SPDX-license-identifier-Apache-2.0",
+    ],
+    license_text: [
+        "LICENSE",
+        "NOTICE.txt",
+    ],
+}
+
 java_library_host {
     name: "grpc-java",
     static_libs: [
@@ -41,4 +64,4 @@
         "grpc-java-okhttp",
     ],
     sdk_version: "current",
-}
\ No newline at end of file
+}
diff --git a/annotation-stubs/Android.bp b/annotation-stubs/Android.bp
index 78cb49d..2f1c39c 100644
--- a/annotation-stubs/Android.bp
+++ b/annotation-stubs/Android.bp
@@ -13,6 +13,15 @@
 // limitations under the License.
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-annotation-stubs",
     host_supported: true,
diff --git a/auth/Android.bp b/auth/Android.bp
index 68d08f4..6d0b6b2 100644
--- a/auth/Android.bp
+++ b/auth/Android.bp
@@ -13,6 +13,15 @@
 // limitations under the License.
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library_host {
     name: "grpc-java-auth",
     srcs: [
diff --git a/compiler/Android.bp b/compiler/Android.bp
index 833559a..a512580 100644
--- a/compiler/Android.bp
+++ b/compiler/Android.bp
@@ -14,6 +14,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 cc_binary_host {
     name: "protoc-gen-grpc-java-plugin",
     srcs: [
diff --git a/context/Android.bp b/context/Android.bp
index 410ce78..814b17a 100644
--- a/context/Android.bp
+++ b/context/Android.bp
@@ -14,6 +14,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-context",
     host_supported: true,
diff --git a/core/Android.bp b/core/Android.bp
index 9bfddc4..d563293 100644
--- a/core/Android.bp
+++ b/core/Android.bp
@@ -13,6 +13,15 @@
 // limitations under the License.
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-core",
     host_supported: true,
diff --git a/netty/shaded/Android.bp b/netty/shaded/Android.bp
index 5aecf42..1902402 100644
--- a/netty/shaded/Android.bp
+++ b/netty/shaded/Android.bp
@@ -19,6 +19,15 @@
 // external dependencies and missing build-system support.
 //
 // WARNING: The artifact version must match the source to avoid runtime issues.
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library_host {
     name: "grpc-java-netty-shaded",
     static_libs: [
diff --git a/okhttp/Android.bp b/okhttp/Android.bp
index 4e329f2..7212a3f 100644
--- a/okhttp/Android.bp
+++ b/okhttp/Android.bp
@@ -13,6 +13,15 @@
 // limitations under the License.
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-okhttp",
     host_supported: true,
diff --git a/protobuf-lite/Android.bp b/protobuf-lite/Android.bp
index f1c4651..2a2ed94 100644
--- a/protobuf-lite/Android.bp
+++ b/protobuf-lite/Android.bp
@@ -14,6 +14,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-protobuf-lite",
     host_supported: true,
diff --git a/protobuf/Android.bp b/protobuf/Android.bp
index 3e1d243..f51c272 100644
--- a/protobuf/Android.bp
+++ b/protobuf/Android.bp
@@ -15,6 +15,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library_host {
     name: "grpc-java-protobuf",
     srcs: [
diff --git a/stub/Android.bp b/stub/Android.bp
index af52701..466195d 100644
--- a/stub/Android.bp
+++ b/stub/Android.bp
@@ -14,6 +14,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-stub",
     host_supported: true,
diff --git a/testing/Android.bp b/testing/Android.bp
index 91dc792..2d2a1c6 100644
--- a/testing/Android.bp
+++ b/testing/Android.bp
@@ -14,6 +14,15 @@
 //
 //
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_grpc-grpc-java_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-Apache-2.0
+    default_applicable_licenses: ["external_grpc-grpc-java_license"],
+}
+
 java_library {
     name: "grpc-java-testing",
     host_supported: true,