From 85155c8ada12dd1d677e597ee63cbf809a279b79 Mon Sep 17 00:00:00 2001 From: Mu-Le Lee Date: Thu, 7 Jul 2022 10:05:09 +0000 Subject: [PATCH] Move LLNDK ABI dumps from vndk/ to platform/ Since vndk libraries don't need to maintain Cross-Version abi compatibility. The newly proposed Cross-Version ABi checking mechanism is applied to only ndk/ and platform/. The reference dumps of LLNDK libraries should get from platform/ to be benefited from this checking mechanism. Test: mkdir -p prebuilts/abi-dumps/platform/UpsideDownCake/64/x86_64/source-based/ && cp prebuilts/abi-dumps/vndk/32/64/x86_64/source-based/libvndksupport.so.lsdump "$_" make libvndksupport -j Bug: 238383845 Change-Id: I663511d60623cd23619166d8d63fd26220a930e2 --- android/paths.go | 4 ++-- cc/library.go | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/android/paths.go b/android/paths.go index d5cec9af7..f8e701822 100644 --- a/android/paths.go +++ b/android/paths.go @@ -1474,7 +1474,7 @@ func pathForModuleOut(ctx ModuleOutPathContext) OutputPath { // PathForVndkRefAbiDump returns an OptionalPath representing the path of the // reference abi dump for the given module. This is not guaranteed to be valid. func PathForVndkRefAbiDump(ctx ModuleInstallPathContext, version, fileName string, - isNdk, isLlndkOrVndk, isGzip bool) OptionalPath { + isNdk, isVndk, isGzip bool) OptionalPath { currentArchType := ctx.Arch().ArchType primaryArchType := ctx.Config().DevicePrimaryArchType() @@ -1486,7 +1486,7 @@ func PathForVndkRefAbiDump(ctx ModuleInstallPathContext, version, fileName strin var dirName string if isNdk { dirName = "ndk" - } else if isLlndkOrVndk { + } else if isVndk { dirName = "vndk" } else { dirName = "platform" // opt-in libs diff --git a/cc/library.go b/cc/library.go index c445a42ca..849d18a12 100644 --- a/cc/library.go +++ b/cc/library.go @@ -1584,10 +1584,10 @@ func (library *libraryDecorator) coverageOutputFilePath() android.OptionalPath { func getRefAbiDumpFile(ctx ModuleContext, vndkVersion, fileName string) android.Path { // The logic must be consistent with classifySourceAbiDump. isNdk := ctx.isNdk(ctx.Config()) - isLlndkOrVndk := ctx.IsLlndkPublic() || (ctx.useVndk() && ctx.isVndk()) + isVndk := ctx.useVndk() && ctx.isVndk() - refAbiDumpTextFile := android.PathForVndkRefAbiDump(ctx, vndkVersion, fileName, isNdk, isLlndkOrVndk, false) - refAbiDumpGzipFile := android.PathForVndkRefAbiDump(ctx, vndkVersion, fileName, isNdk, isLlndkOrVndk, true) + refAbiDumpTextFile := android.PathForVndkRefAbiDump(ctx, vndkVersion, fileName, isNdk, isVndk, false) + refAbiDumpGzipFile := android.PathForVndkRefAbiDump(ctx, vndkVersion, fileName, isNdk, isVndk, true) if refAbiDumpTextFile.Valid() { if refAbiDumpGzipFile.Valid() {