diff --git a/cc/builder.go b/cc/builder.go index db4cb4fd5..fcc431816 100644 --- a/cc/builder.go +++ b/cc/builder.go @@ -187,12 +187,12 @@ var ( sAbiLink = pctx.AndroidStaticRule("sAbiLink", blueprint.RuleParams{ - Command: "$sAbiLinker -o ${out} $symbolFilter -arch $arch -api $api $exportedHeaderFlags @${out}.rsp ", + Command: "$sAbiLinker -o ${out} $symbolFilter -arch $arch $exportedHeaderFlags @${out}.rsp ", CommandDeps: []string{"$sAbiLinker"}, Rspfile: "${out}.rsp", RspfileContent: "${in}", }, - "symbolFilter", "arch", "api", "exportedHeaderFlags") + "symbolFilter", "arch", "exportedHeaderFlags") _ = pctx.SourcePathVariable("sAbiDiffer", "prebuilts/build-tools/${config.HostPrebuiltTag}/bin/header-abi-diff") @@ -681,27 +681,18 @@ func TransformObjToDynamicBinary(ctx android.ModuleContext, // Generate a rule to combine .dump sAbi dump files from multiple source files // into a single .ldump sAbi dump file func TransformDumpToLinkedDump(ctx android.ModuleContext, sAbiDumps android.Paths, soFile android.Path, - symbolFile android.OptionalPath, apiLevel, baseName, exportedHeaderFlags string) android.OptionalPath { + baseName, exportedHeaderFlags string) android.OptionalPath { outputFile := android.PathForModuleOut(ctx, baseName+".lsdump") - var symbolFilterStr string - var linkedDumpDep android.Path - if symbolFile.Valid() { - symbolFilterStr = "-v " + symbolFile.Path().String() - linkedDumpDep = symbolFile.Path() - } else { - linkedDumpDep = soFile - symbolFilterStr = "-so " + soFile.String() - } + symbolFilterStr := "-so " + soFile.String() ctx.Build(pctx, android.BuildParams{ Rule: sAbiLink, Description: "header-abi-linker " + outputFile.Base(), Output: outputFile, Inputs: sAbiDumps, - Implicit: linkedDumpDep, + Implicit: soFile, Args: map[string]string{ - "symbolFilter": symbolFilterStr, - "arch": ctx.Arch().ArchType.Name, - "api": apiLevel, + "symbolFilter": symbolFilterStr, + "arch": ctx.Arch().ArchType.Name, "exportedHeaderFlags": exportedHeaderFlags, }, }) diff --git a/cc/library.go b/cc/library.go index 4a900ef4e..adbd6b529 100644 --- a/cc/library.go +++ b/cc/library.go @@ -620,11 +620,6 @@ func (library *libraryDecorator) linkSAbiDumpFiles(ctx ModuleContext, objs Objec //Also take into account object re-use. if len(objs.sAbiDumpFiles) > 0 && ctx.createVndkSourceAbiDump() { refSourceDumpFile := android.PathForVndkRefAbiDump(ctx, "current", fileName, vndkVsNdk(ctx), true) - versionScript := android.OptionalPathForModuleSrc(ctx, library.Properties.Version_script) - var symbolFile android.OptionalPath - if versionScript.Valid() { - symbolFile = versionScript - } exportIncludeDirs := library.flagExporter.exportedIncludes(ctx) var SourceAbiFlags []string for _, dir := range exportIncludeDirs.Strings() { @@ -634,7 +629,7 @@ func (library *libraryDecorator) linkSAbiDumpFiles(ctx ModuleContext, objs Objec SourceAbiFlags = append(SourceAbiFlags, reexportedInclude) } exportedHeaderFlags := strings.Join(SourceAbiFlags, " ") - library.sAbiOutputFile = TransformDumpToLinkedDump(ctx, objs.sAbiDumpFiles, soFile, symbolFile, "current", fileName, exportedHeaderFlags) + library.sAbiOutputFile = TransformDumpToLinkedDump(ctx, objs.sAbiDumpFiles, soFile, fileName, exportedHeaderFlags) if refSourceDumpFile.Valid() { unzippedRefDump := UnzipRefDump(ctx, refSourceDumpFile.Path(), fileName) library.sAbiDiff = SourceAbiDiff(ctx, library.sAbiOutputFile.Path(), unzippedRefDump, fileName)