Loading api/StubLibraries.bp +56 −0 Original line number Diff line number Diff line Loading @@ -1214,6 +1214,32 @@ droidstubs { api_levels_sdk_type: "module-lib", } // Create a single jar containing the whole module-lib API surface. // This is needed because Metalava only consumes the first jar file it is given // and ignores the rest. java_library { name: "android_module_stubs_complete_current_with_test_libs", static_libs: [ "android_module_stubs_current_with_test_libs", "framework-updatable-stubs-module_libs_api-exportable", ], defaults: ["android.jar_defaults"], visibility: [ "//visibility:override", "//visibility:private", ], } // Produces an `api-versions.xml` file that includes up-to-date information // about all the module-lib APIs, both updatable and non-updatable and historic // information about all previous dessert and SDK extension releases. droidstubs { name: "api_versions_module_lib_complete", defaults: ["api_versions_complete_defaults"], srcs: [":android_module_stubs_complete_current_with_test_libs{.jar}"], api_levels_sdk_type: "module-lib", } // Produces an `api-versions.xml` file that includes up-to-date information // about only the non-updatable system-server APIs and historic information // about all previous dessert and SDK extension releases. That historic Loading @@ -1226,6 +1252,36 @@ droidstubs { api_levels_sdk_type: "system-server", } // Create a single jar containing the whole system-server API surface. // This is needed because Metalava only consumes the first jar file it is given // and ignores the rest. java_library { name: "android_system_server_stubs_complete_current_with_test_libs", static_libs: [ "android_system_server_stubs_current_with_test_libs", // system-server extends module-lib but libraries which only service-* // libraries provided system-server APIs, so include module-lib APIs for // the others, e.g. framework-* libraries. "framework-updatable-stubs-module_libs_api-exportable", "framework-updatable-stubs-system_server_api-exportable", ], defaults: ["android.jar_defaults"], visibility: [ "//visibility:override", "//visibility:private", ], } // Produces an `api-versions.xml` file that includes up-to-date information // about all the system-server APIs, both updatable and non-updatable and // historic information about all previous dessert and SDK extension releases. droidstubs { name: "api_versions_system_server_complete", defaults: ["api_versions_complete_defaults"], srcs: [":android_system_server_stubs_complete_current_with_test_libs{.jar}"], api_levels_sdk_type: "system-server", } ///////////////////////////////////////////////////////////////////// // hwbinder.stubs provides APIs required for building HIDL Java // libraries. Loading api/api.go +21 −0 Original line number Diff line number Diff line Loading @@ -386,6 +386,26 @@ func createMergedFrameworkModuleLibStubs(ctx android.LoadHookContext, modules [] ctx.CreateModule(java.LibraryFactory, &props) } func createMergedFrameworkSystemServerExportableStubs(ctx android.LoadHookContext, bootclasspath, system_server_classpath []string) { // The user of this module compiles against the "core" SDK and against non-updatable bootclasspathModules, // so remove to avoid dupes. bootclasspathModules := removeAll(bootclasspath, core_libraries_modules) bootclasspathModules = removeAll(bootclasspath, non_updatable_modules) modules := append( // Include all the module-lib APIs from the bootclasspath libraries. transformArray(bootclasspathModules, "", ".stubs.exportable.module_lib"), // Then add all the system-server APIs from the service-* libraries. transformArray(system_server_classpath, "", ".stubs.exportable.system_server")..., ) props := libraryProps{} props.Name = proptools.StringPtr("framework-updatable-stubs-system_server_api-exportable") props.Static_libs = modules props.Sdk_version = proptools.StringPtr("system_server_current") props.Visibility = []string{"//frameworks/base"} props.Is_stubs_module = proptools.BoolPtr(true) ctx.CreateModule(java.LibraryFactory, &props) } func createPublicStubsSourceFilegroup(ctx android.LoadHookContext, modules []string) { props := fgProps{} props.Name = proptools.StringPtr("all-modules-public-stubs-source") Loading Loading @@ -531,6 +551,7 @@ func (a *CombinedApis) createInternalModules(ctx android.LoadHookContext) { createMergedSystemExportableStubs(ctx, bootclasspath) createMergedTestExportableStubsForNonUpdatableModules(ctx) createMergedFrameworkModuleLibExportableStubs(ctx, bootclasspath) createMergedFrameworkSystemServerExportableStubs(ctx, bootclasspath, system_server_classpath) createMergedAnnotationsFilegroups(ctx, bootclasspath, system_server_classpath) Loading Loading
api/StubLibraries.bp +56 −0 Original line number Diff line number Diff line Loading @@ -1214,6 +1214,32 @@ droidstubs { api_levels_sdk_type: "module-lib", } // Create a single jar containing the whole module-lib API surface. // This is needed because Metalava only consumes the first jar file it is given // and ignores the rest. java_library { name: "android_module_stubs_complete_current_with_test_libs", static_libs: [ "android_module_stubs_current_with_test_libs", "framework-updatable-stubs-module_libs_api-exportable", ], defaults: ["android.jar_defaults"], visibility: [ "//visibility:override", "//visibility:private", ], } // Produces an `api-versions.xml` file that includes up-to-date information // about all the module-lib APIs, both updatable and non-updatable and historic // information about all previous dessert and SDK extension releases. droidstubs { name: "api_versions_module_lib_complete", defaults: ["api_versions_complete_defaults"], srcs: [":android_module_stubs_complete_current_with_test_libs{.jar}"], api_levels_sdk_type: "module-lib", } // Produces an `api-versions.xml` file that includes up-to-date information // about only the non-updatable system-server APIs and historic information // about all previous dessert and SDK extension releases. That historic Loading @@ -1226,6 +1252,36 @@ droidstubs { api_levels_sdk_type: "system-server", } // Create a single jar containing the whole system-server API surface. // This is needed because Metalava only consumes the first jar file it is given // and ignores the rest. java_library { name: "android_system_server_stubs_complete_current_with_test_libs", static_libs: [ "android_system_server_stubs_current_with_test_libs", // system-server extends module-lib but libraries which only service-* // libraries provided system-server APIs, so include module-lib APIs for // the others, e.g. framework-* libraries. "framework-updatable-stubs-module_libs_api-exportable", "framework-updatable-stubs-system_server_api-exportable", ], defaults: ["android.jar_defaults"], visibility: [ "//visibility:override", "//visibility:private", ], } // Produces an `api-versions.xml` file that includes up-to-date information // about all the system-server APIs, both updatable and non-updatable and // historic information about all previous dessert and SDK extension releases. droidstubs { name: "api_versions_system_server_complete", defaults: ["api_versions_complete_defaults"], srcs: [":android_system_server_stubs_complete_current_with_test_libs{.jar}"], api_levels_sdk_type: "system-server", } ///////////////////////////////////////////////////////////////////// // hwbinder.stubs provides APIs required for building HIDL Java // libraries. Loading
api/api.go +21 −0 Original line number Diff line number Diff line Loading @@ -386,6 +386,26 @@ func createMergedFrameworkModuleLibStubs(ctx android.LoadHookContext, modules [] ctx.CreateModule(java.LibraryFactory, &props) } func createMergedFrameworkSystemServerExportableStubs(ctx android.LoadHookContext, bootclasspath, system_server_classpath []string) { // The user of this module compiles against the "core" SDK and against non-updatable bootclasspathModules, // so remove to avoid dupes. bootclasspathModules := removeAll(bootclasspath, core_libraries_modules) bootclasspathModules = removeAll(bootclasspath, non_updatable_modules) modules := append( // Include all the module-lib APIs from the bootclasspath libraries. transformArray(bootclasspathModules, "", ".stubs.exportable.module_lib"), // Then add all the system-server APIs from the service-* libraries. transformArray(system_server_classpath, "", ".stubs.exportable.system_server")..., ) props := libraryProps{} props.Name = proptools.StringPtr("framework-updatable-stubs-system_server_api-exportable") props.Static_libs = modules props.Sdk_version = proptools.StringPtr("system_server_current") props.Visibility = []string{"//frameworks/base"} props.Is_stubs_module = proptools.BoolPtr(true) ctx.CreateModule(java.LibraryFactory, &props) } func createPublicStubsSourceFilegroup(ctx android.LoadHookContext, modules []string) { props := fgProps{} props.Name = proptools.StringPtr("all-modules-public-stubs-source") Loading Loading @@ -531,6 +551,7 @@ func (a *CombinedApis) createInternalModules(ctx android.LoadHookContext) { createMergedSystemExportableStubs(ctx, bootclasspath) createMergedTestExportableStubsForNonUpdatableModules(ctx) createMergedFrameworkModuleLibExportableStubs(ctx, bootclasspath) createMergedFrameworkSystemServerExportableStubs(ctx, bootclasspath, system_server_classpath) createMergedAnnotationsFilegroups(ctx, bootclasspath, system_server_classpath) Loading