summaryrefslogtreecommitdiff
path: root/java/rro.go
diff options
context:
space:
mode:
author Spandan Das <spandandas@google.com> 2024-12-08 18:22:45 +0000
committer Spandan Das <spandandas@google.com> 2024-12-08 18:30:28 +0000
commitaf8a3f5eaf70b817e43ab8e0a4908a7a5025c85f (patch)
tree9e63a31897406478b9a67a37e54836d4b203a627 /java/rro.go
parentd2505873e521984f6d4732d4acd9f87fe338d159 (diff)
Bugfix for LOCAL_CERTIFICATE of AutogeneratedRuntimeResourceOverlay
LOCAL_CERTIFICATE of these modules are currently set to `PRESIGNED`, since soong generates the build rules to sign the apk. However, this is an incorrect interpretation of `PRESIGNED`. This keyword means that the apk was signed with a release key, and not dev keys. Since Soong signs the autogenerated rros with dev keys, drop `PRESIGNED` from `LOCAL_CERTIFICATE` and replace it with the dev key string. Test: verified that `LOCAL_CERTIFICATE` of `Settings__aosp_cf_x86_64_phone__auto_generated_rro_vendor` in the autogenerated Android.mk is no longer PRESIGNED. Bug: 375277835 Change-Id: I024f88f9ee887323e93df8338af5f8b089025b93
Diffstat (limited to 'java/rro.go')
-rw-r--r--java/rro.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/java/rro.go b/java/rro.go
index d277e4ab7..ab4fafa7f 100644
--- a/java/rro.go
+++ b/java/rro.go
@@ -290,7 +290,8 @@ type AutogenRuntimeResourceOverlay struct {
properties AutogenRuntimeResourceOverlayProperties
- outputFile android.Path
+ certificate Certificate
+ outputFile android.Path
}
type AutogenRuntimeResourceOverlayProperties struct {
@@ -380,7 +381,8 @@ func (a *AutogenRuntimeResourceOverlay) GenerateAndroidBuildActions(ctx android.
return
}
// Sign the built package
- _, certificates := processMainCert(a.ModuleBase, "", nil, ctx)
+ var certificates []Certificate
+ a.certificate, certificates = processMainCert(a.ModuleBase, "", nil, ctx)
signed := android.PathForModuleOut(ctx, "signed", a.Name()+".apk")
SignAppPackage(ctx, signed, a.exportPackage, certificates, nil, nil, "")
a.outputFile = signed