Ready more build rules for dir move

Tweak some visibilities and set up more filegroups to enable moving
the ApiDocs.bp and StubLibraries.bp files into the api subdir.

Bug: 271563074
Test: m
(cherry picked from https://android-review.googlesource.com/q/commit:ca6e67a66ba3448b00bd24762ab9494fb54fa8cd)
Merged-In: Ib2776dfc6c67b2042fb2f43a1251cd6f0ba61dc7
Change-Id: Ib2776dfc6c67b2042fb2f43a1251cd6f0ba61dc7
This commit is contained in:
Anton Hansson
2023-03-03 17:55:09 +00:00
committed by Cherrypicker Worker
parent b1cd493738
commit a5d4de956c
5 changed files with 19 additions and 13 deletions

View File

@@ -606,7 +606,7 @@ filegroup {
"core/java/**/*.logtags",
"**/package.html",
],
visibility: ["//visibility:private"],
visibility: ["//frameworks/base/api"],
}
// Defaults for all stubs that include the non-updatable framework. These defaults do not include
@@ -620,12 +620,10 @@ stubs_defaults {
java_version: "1.8",
arg_files: [":frameworks-base-core-AndroidManifest.xml"],
aidl: {
local_include_dirs: [
"media/aidl",
"telephony/java",
],
include_dirs: [
"frameworks/av/aidl",
"frameworks/base/media/aidl",
"frameworks/base/telephony/java",
"frameworks/native/libs/permission/aidl",
"packages/modules/Bluetooth/framework/aidl-export",
"packages/modules/Connectivity/framework/aidl-export",
@@ -661,7 +659,7 @@ stubs_defaults {
annotations_enabled: true,
previous_api: ":android.api.public.latest",
merge_annotations_dirs: ["metalava-manual"],
defaults_visibility: ["//visibility:private"],
defaults_visibility: ["//frameworks/base/api"],
visibility: ["//frameworks/base/api"],
}
@@ -689,7 +687,6 @@ stubs_defaults {
// NOTE: The below can be removed once the prebuilt stub contains IKE.
"sdk_system_current_android.net.ipsec.ike",
],
defaults_visibility: ["//visibility:private"],
}
build = [

View File

@@ -182,10 +182,10 @@ droidstubs {
// using droiddoc
/////////////////////////////////////////////////////////////////////
framework_docs_only_args = " -android -manifest $(location core/res/AndroidManifest.xml) " +
framework_docs_only_args = " -android -manifest $(location :frameworks-base-core-AndroidManifest.xml) " +
"-metalavaApiSince " +
"-werror -lerror -hide 111 -hide 113 -hide 125 -hide 126 -hide 127 -hide 128 " +
"-overview $(location core/java/overview.html) " +
"-overview $(location :frameworks-base-java-overview) " +
// Federate Support Library references against local API file.
"-federate SupportLib https://developer.android.com " +
"-federationapi SupportLib $(location :current-support-api) " +
@@ -218,16 +218,16 @@ doc_defaults {
"sdk.preview 0",
],
arg_files: [
"core/res/AndroidManifest.xml",
"core/java/overview.html",
":frameworks-base-core-AndroidManifest.xml",
":frameworks-base-java-overview",
":current-support-api",
":current-androidx-api",
],
// TODO(b/169090544): remove below aidl includes.
aidl: {
local_include_dirs: ["media/aidl"],
include_dirs: [
"frameworks/av/aidl",
"frameworks/base/media/aidl",
"frameworks/native/libs/permission/aidl",
],
},

View File

@@ -515,6 +515,7 @@ droidstubs {
],
api_levels_sdk_type: "public",
extensions_info_file: ":sdk-extensions-info",
visibility: ["//frameworks/base"],
}
droidstubs {

View File

@@ -421,6 +421,11 @@ aidl_interface {
},
}
filegroup {
name: "frameworks-base-java-overview",
srcs: ["overview.html"],
}
// Avoid including Parcelable classes as we don't want to have two copies of
// Parcelable cross the libraries. This is used by telephony-common (frameworks/opt/telephony)
// and TeleService app (packages/services/Telephony).

View File

@@ -10,5 +10,8 @@ package {
filegroup {
name: "framework-mime-sources",
srcs: ["**/*.java"],
visibility: ["//frameworks/base"],
visibility: [
"//frameworks/base",
"//frameworks/base/api",
],
}