platform_build_soong/java
Paul Duffin 1e18e98b14 Allow implementation details to be excluded from signature patterns file
Previously, the signature-patterns.csv file (which was output in an sdk
snapshot) included implementation details, e.g. the names of classes
that are not part of any API, including the hidden API. This change
allows a bootclasspath_fragment module owner to customize the generated
signature patterns file to remove as many implementation details as
possible from the sdk snapshot. That means that implementation only
changes would not require that sdk snapshots be updated in sync with
the corresponding APEX.

Module owners can remove implementation in the following ways:
1) Limit the number of packages that are treated as split packages by
   explicitly specifying the split packages in the split_packages
   property. A split package is one whose classes are provided by
   separate bootclasspath_fragment modules and so the signature
   patterns has to include every class in that package provided by a
   specific bootclasspath_fragment module, including implementation
   classes, instead of just listing the package.

   The default is to treat all packages as being split, so if no
   split_packages is specified then it defaults to ["*"] which matches
   all packages. Assuming that no package was split unless specifically
   stated would require that all the modules that had split packages
   explicitly list them before this change could be submitted as
   without them this change would break the build.

   Once all existing modules with split packages have been updated to
   include them then the default may be changed.

2) Adding package prefixes for any hierarchy of packages that are
   owned solely by that bootclasspath_fragment. This removes the need
   to list the packages in that hierarchy, including implementation
   specific packages.

Bug: 194063708
Test: atest --host verify_overlaps_test signature_patterns_test
      m out/soong/hiddenapi/hiddenapi-flags.csv
      - manually change files to cause difference in flags to check
        that it detects the differences.
Change-Id: If2f90cfc41b6fff9fa4ac8b9d4973110938b9392
2021-10-05 15:47:05 +01:00
..
config Revert "Time out and dump stacks from R8 processes after 30 minutes" 2021-08-05 17:04:06 -07:00
core-libraries [LSC] Add LOCAL_LICENSE_KINDS to build/soong 2021-08-27 13:30:35 -07:00
aapt2.go Improve comments in java/aapt2.go 2020-11-30 14:16:02 -08:00
aar.go Add {.aar} support for android_library 2021-09-14 21:02:43 +00:00
Android.bp Add initial bp2build support for converting android_app_certificate modules. 2021-07-28 06:51:07 -04:00
android_manifest.go Don't add uses_libs/optional_uses_libs to the manifest_fixer. 2021-08-20 15:54:42 +01:00
android_resources.go Add preparer for overlay pre-singleton registration 2021-03-22 22:09:53 +00:00
androidmk.go Remove unnecessary additionalCheckedModules field 2021-10-04 10:42:56 +01:00
androidmk_test.go add the LOCAL_DISABLE_TEST_CONFIG variable 2021-05-27 17:53:46 -07:00
app.go Bp2Build common properties auto-handling 2021-10-04 14:43:04 +00:00
app_builder.go Move android package on top of remotexec 2021-03-18 16:17:34 -07:00
app_import.go Fix DONT_UNCOMPRESS_PRIV_APPS_DEXS for android_app_import. 2021-09-01 15:44:50 +01:00
app_import_test.go Fix DONT_UNCOMPRESS_PRIV_APPS_DEXS for android_app_import. 2021-09-01 15:44:50 +01:00
app_set.go Break up app.go. 2020-12-21 12:31:51 -08:00
app_set_test.go Remove uses of buildDir from java/app_set_test.go 2021-03-24 00:01:15 +00:00
app_test.go Rename BuildDir and NinjaBuildDir. 2021-08-27 10:08:49 +02:00
base.go Remove unnecessary additionalCheckedModules field 2021-10-04 10:42:56 +01:00
boot_jars.go Disable boot jars package check if no boot jars have been configured 2021-06-22 14:55:30 +01:00
bootclasspath.go Remove fallback code path for missing BCP fragments that is no longer 2021-09-16 00:55:53 +01:00
bootclasspath_fragment.go Allow implementation details to be excluded from signature patterns file 2021-10-05 15:47:05 +01:00
bootclasspath_fragment_test.go Fix tests to use correct fixtures for configuring (Apex)BootJars. 2021-08-10 15:35:52 +01:00
builder.go Enable compose kotlinc plugin when depending on the compose runtime 2021-09-20 09:12:42 -07:00
classpath_element.go Add ClasspathElement support 2021-06-18 11:46:52 +01:00
classpath_fragment.go Rename UpdatableBootJars to ApexBootJars. 2021-07-22 17:35:42 +01:00
device_host_converter.go Clear remains of java.Dependency interface. 2021-03-05 14:57:51 +00:00
device_host_converter_test.go Revert "Make lots of tests run in parallel" 2020-10-09 18:34:24 -07:00
dex.go Add support for d8 --main-dex-rules 2021-09-16 19:14:30 -07:00
dexpreopt.go Revert^2 "Preopt APEX system server jars." 2021-09-16 06:25:26 +00:00
dexpreopt_bootjars.go Remove updatable-bcp-packages.txt. 2021-09-24 03:19:05 +00:00
dexpreopt_bootjars_test.go Build boot images in bootclasspath_fragment/platform_bootclasspath 2021-05-12 21:51:27 +01:00
dexpreopt_config.go Merge "Rename UpdatableBootJars to ApexBootJars." 2021-07-26 17:59:36 +00:00
dexpreopt_test.go Revert^2 "Preopt APEX system server jars." 2021-09-16 06:25:26 +00:00
droiddoc.go Stop filtering html files from droidstubs input 2021-06-07 16:02:53 +01:00
droiddoc_test.go Remove extraneous calls to TestingBuildParams.RelativeToTop() 2021-03-30 20:03:22 +01:00
droidstubs.go Add annotations.zip support to java_sdk_library 2021-09-22 17:23:10 +01:00
droidstubs_test.go Use system stubs for framework-doc-system-stubs. 2021-06-29 22:25:57 +01:00
gen.go Take Module implementations out of java/java.go. 2021-03-19 15:46:38 -07:00
genrule.go
hiddenapi.go Propagate the dex jar path as an OptionalPath which is either valid or 2021-09-23 17:19:55 +01:00
hiddenapi_modular.go Allow implementation details to be excluded from signature patterns file 2021-10-05 15:47:05 +01:00
hiddenapi_monolithic.go Separate creation of signature patterns from overlap checking 2021-08-06 13:40:34 +01:00
hiddenapi_singleton.go Drop "prebuilt_" prefixes from names registered in ApexInfo.InApexXxx. 2021-05-26 17:05:17 +01:00
hiddenapi_singleton_test.go Propagate the dex jar path as an OptionalPath which is either valid or 2021-09-23 17:19:55 +01:00
jacoco.go Added quotes to protect wildcard 2021-06-30 14:29:49 -04:00
jacoco_test.go Added quotes to protect wildcard 2021-06-30 14:29:49 -04:00
java.go Merge "Preopt APEX system server jars for java_import." 2021-10-02 03:33:22 +00:00
java_resources.go
java_test.go Propagate the dex jar path as an OptionalPath which is either valid or 2021-09-23 17:19:55 +01:00
jdeps.go Convert java.Dependency to JavaInfo provider 2021-02-09 15:36:25 -08:00
jdeps_test.go Revert "Make lots of tests run in parallel" 2020-10-09 18:34:24 -07:00
kotlin.go Enable compose kotlinc plugin when depending on the compose runtime 2021-09-20 09:12:42 -07:00
kotlin_test.go Enable compose kotlinc plugin when depending on the compose runtime 2021-09-20 09:12:42 -07:00
legacy_core_platform_api_usage.go Add test to TestJavaStableSdkVersion for legacy core platform 2021-09-16 11:12:43 +01:00
lint.go make system server modules use filtered lint database 2021-07-05 16:57:34 +00:00
lint_defaults.txt Disable lint checks which do not apply in the platform 2021-07-24 14:48:19 +00:00
lint_test.go make system server modules use filtered lint database 2021-07-05 16:57:34 +00:00
OWNERS Update dex_preopt related OWNERS 2021-06-17 17:05:39 +01:00
platform_bootclasspath.go Remove updatable-bcp-packages.txt. 2021-09-24 03:19:05 +00:00
platform_bootclasspath_test.go Make CheckHiddenAPIRuleInputs more reusable 2021-06-20 19:09:09 +01:00
platform_compat_config.go Refactor SdkMemberType.AddDependencies() 2021-08-31 17:07:07 +01:00
platform_compat_config_test.go Add platform_compat_config to sdk 2021-03-22 19:13:40 +00:00
plugin.go Register java_plugin in PrepareForTestWithJavaBuildComponents 2021-03-24 00:01:15 +00:00
plugin_test.go Replace android.BuildOs with Config.BuildOS 2021-07-20 12:46:48 -07:00
prebuilt_apis.go Remove special case code for obsolete files 2021-04-13 19:09:48 +01:00
proto.go Improve java.go readability. 2021-03-15 13:58:44 -07:00
robolectric.go Merge "Add phony name for robolectric tests" 2021-09-24 19:51:41 +00:00
rro.go Port module_partition logic for RRO from Make to Soong 2021-06-08 17:53:31 +00:00
rro_test.go Port module_partition logic for RRO from Make to Soong 2021-06-08 17:53:31 +00:00
sdk.go "module_current" and "system_server_current" should contain ART's @SystemApi(MODULE_LIBRARIES) 2021-06-29 22:05:58 +01:00
sdk_library.go Merge "Remove updatable-bcp-packages.txt." 2021-09-26 03:34:28 +00:00
sdk_library_external.go Remove global state from sysprop libraries 2021-02-26 16:28:12 -08:00
sdk_library_test.go Add annotations.zip support to java_sdk_library 2021-09-22 17:23:10 +01:00
sdk_test.go Replace android.BuildOs with Config.BuildOS 2021-07-20 12:46:48 -07:00
support_libraries.go
system_modules.go Refactor SdkMemberType.AddDependencies() 2021-08-31 17:07:07 +01:00
system_modules_test.go Remove varargs from RunTest(t *testing.T) 2021-03-31 16:03:59 +01:00
systemserver_classpath_fragment.go Update variable name in error messages. 2021-10-04 15:43:39 +01:00
systemserver_classpath_fragment_test.go Rename generate proto config file to match classpath type. 2021-05-24 12:52:01 +01:00
testing.go Add annotations.zip support to java_sdk_library 2021-09-22 17:23:10 +01:00
tradefed.go