summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
author Justin Yun <justinyun@google.com> 2024-05-07 10:22:19 +0900
committer Justin Yun <justinyun@google.com> 2024-05-10 10:00:14 +0900
commit40182b6ff33ed7d91837212000524e74bf2392c7 (patch)
treee0bfc773c5d5864a548dbe1d4f291b7b59575d4f /python
parentdd056e087eddbee56d205694ecc9f51c435d49dc (diff)
Remove duplicated CollectDependencyAconfigFiles()
android.ModuleBase already calls aconfigUpdateAndroidBuildActions() that is the same with CollectDependencyAconfigFiles(). Remove the CollectDependencyAconfigFiles() to avoid duplication with aconfigUpdateAndroidBuildActions(). To make the aconfig information available in GenerateAndroidBuildActions() of all modules, call aconfigUpdateAndroidBuildActions() before calling GenerateAndroidBuildActions() of each module. Also, we don't need SetAconfigFileMkEntries(), which is a duplicate of aconfigUpdateAndroidMkData() Bug: 335363964 Test: diff `adb shell printflags` before and after the change. Change-Id: I52808e442e9fed7db1eae7b7c5ed0b1c5ba74f5d
Diffstat (limited to 'python')
-rw-r--r--python/binary.go5
-rw-r--r--python/test.go3
2 files changed, 1 insertions, 7 deletions
diff --git a/python/binary.go b/python/binary.go
index c84eeeedb..b935aba45 100644
--- a/python/binary.go
+++ b/python/binary.go
@@ -71,9 +71,6 @@ type PythonBinaryModule struct {
installedDest android.Path
androidMkSharedLibs []string
-
- // Aconfig files for all transitive deps. Also exposed via TransitiveDeclarationsInfo
- mergedAconfigFiles map[string]android.Paths
}
var _ android.AndroidMkEntriesProvider = (*PythonBinaryModule)(nil)
@@ -106,7 +103,6 @@ func (p *PythonBinaryModule) GenerateAndroidBuildActions(ctx android.ModuleConte
p.buildBinary(ctx)
p.installedDest = ctx.InstallFile(installDir(ctx, "bin", "", ""),
p.installSource.Base(), p.installSource)
- android.CollectDependencyAconfigFiles(ctx, &p.mergedAconfigFiles)
}
func (p *PythonBinaryModule) buildBinary(ctx android.ModuleContext) {
@@ -170,7 +166,6 @@ func (p *PythonBinaryModule) AndroidMkEntries() []android.AndroidMkEntries {
entries.SetString("LOCAL_MODULE_STEM", stem)
entries.AddStrings("LOCAL_SHARED_LIBRARIES", p.androidMkSharedLibs...)
entries.SetBool("LOCAL_CHECK_ELF_FILES", false)
- android.SetAconfigFileMkEntries(&p.ModuleBase, entries, p.mergedAconfigFiles)
})
return []android.AndroidMkEntries{entries}
diff --git a/python/test.go b/python/test.go
index 2b939e7e4..85decf931 100644
--- a/python/test.go
+++ b/python/test.go
@@ -18,6 +18,7 @@ import (
"fmt"
"android/soong/testing"
+
"github.com/google/blueprint/proptools"
"android/soong/android"
@@ -151,7 +152,6 @@ func (p *PythonTestModule) GenerateAndroidBuildActions(ctx android.ModuleContext
// just use buildBinary() so that the binary is not installed into the location
// it would be for regular binaries.
p.PythonLibraryModule.GenerateAndroidBuildActions(ctx)
- android.CollectDependencyAconfigFiles(ctx, &p.mergedAconfigFiles)
p.buildBinary(ctx)
var configs []tradefed.Option
@@ -227,7 +227,6 @@ func (p *PythonTestModule) AndroidMkEntries() []android.AndroidMkEntries {
}
entries.SetBoolIfTrue("LOCAL_DISABLE_AUTO_GENERATE_TEST_CONFIG", !BoolDefault(p.binaryProperties.Auto_gen_config, true))
- android.SetAconfigFileMkEntries(&p.ModuleBase, entries, p.mergedAconfigFiles)
p.testProperties.Test_options.SetAndroidMkEntries(entries)
})