From 438eb57a2744b9b0bd38a5526e67cacf43c42b31 Mon Sep 17 00:00:00 2001 From: Paul Duffin Date: Fri, 21 May 2021 16:58:23 +0100 Subject: Separate monolithic hidden API processing from hiddenAPIFlagFileInfo The hiddenAPIFlagFileInfo was being used for both the input and output of bootclasspath_fragment and platform_bootclasspath and also to pass information around to various hidden API rule methods. Supporting multiple different uses in this way made it hard to reason about. This change creates a separate structure for use by the platform_bootclasspath. Follow up changes will split out other functionality into separate types. Bug: 179354495 Test: m com.android.art com.android.ipsec com.android.os.statsd com.android.conscrypt - verify that this does not change the contents of the apex files Change-Id: Ia5c5f65ae5645486c42819c669a8601588217f88 --- java/bootclasspath_fragment.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'java/bootclasspath_fragment.go') diff --git a/java/bootclasspath_fragment.go b/java/bootclasspath_fragment.go index e151d6315..9310b12b1 100644 --- a/java/bootclasspath_fragment.go +++ b/java/bootclasspath_fragment.go @@ -651,7 +651,7 @@ type bootclasspathFragmentSdkMemberProperties struct { Core_platform_stub_libs []string // Flag files by *hiddenAPIFlagFileCategory - Flag_files_by_category map[*hiddenAPIFlagFileCategory]android.Paths + Flag_files_by_category FlagFilesByCategory // The path to the generated stub-flags.csv file. Stub_flags_path android.OptionalPath @@ -689,7 +689,7 @@ func (b *bootclasspathFragmentSdkMemberProperties) PopulateFromVariant(ctx andro // Get the flag file information from the module. mctx := ctx.SdkModuleContext() flagFileInfo := mctx.OtherModuleProvider(module, hiddenAPIFlagFileInfoProvider).(hiddenAPIFlagFileInfo) - b.Flag_files_by_category = flagFileInfo.categoryToPaths + b.Flag_files_by_category = flagFileInfo.FlagFilesByCategory // Copy all the generated file paths. b.Stub_flags_path = pathsToOptionalPath(flagFileInfo.StubFlagsPaths) -- cgit v1.2.3-59-g8ed1b