summaryrefslogtreecommitdiff
path: root/java/rro.go
diff options
context:
space:
mode:
author Cole Faust <colefaust@google.com> 2024-11-18 16:49:19 -0800
committer Cole Faust <colefaust@google.com> 2024-11-18 16:53:35 -0800
commiteb9c148744563df3f4180aa658434c92a2094f7b (patch)
tree38a3afeed6aefc5a73cb9148c5e832984b550a06 /java/rro.go
parent385f75bfacf3a29949e3acbccd0cbc9baf347ee4 (diff)
Make the certificate property Configurable
By user request. Fixes: 379649314 Test: m nothing --no-skip-soong-tests Change-Id: I2e8c6c1c3556d4178eca2044d200c109669c6e93
Diffstat (limited to 'java/rro.go')
-rw-r--r--java/rro.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/java/rro.go b/java/rro.go
index 8bb9be2eb..f225e1f4e 100644
--- a/java/rro.go
+++ b/java/rro.go
@@ -50,7 +50,7 @@ type RuntimeResourceOverlay struct {
type RuntimeResourceOverlayProperties struct {
// the name of a certificate in the default certificate directory or an android_app_certificate
// module name in the form ":module".
- Certificate *string
+ Certificate proptools.Configurable[string] `android:"replace_instead_of_append"`
// Name of the signing certificate lineage file.
Lineage *string
@@ -119,7 +119,7 @@ func (r *RuntimeResourceOverlay) DepsMutator(ctx android.BottomUpMutatorContext)
r.aapt.deps(ctx, sdkDep)
}
- cert := android.SrcIsModule(String(r.properties.Certificate))
+ cert := android.SrcIsModule(r.properties.Certificate.GetOrDefault(ctx, ""))
if cert != "" {
ctx.AddDependency(ctx.Module(), certificateTag, cert)
}
@@ -166,7 +166,7 @@ func (r *RuntimeResourceOverlay) GenerateAndroidBuildActions(ctx android.ModuleC
// Sign the built package
_, _, certificates := collectAppDeps(ctx, r, false, false)
- r.certificate, certificates = processMainCert(r.ModuleBase, String(r.properties.Certificate), certificates, ctx)
+ r.certificate, certificates = processMainCert(r.ModuleBase, r.properties.Certificate.GetOrDefault(ctx, ""), certificates, ctx)
signed := android.PathForModuleOut(ctx, "signed", r.Name()+".apk")
var lineageFile android.Path
if lineage := String(r.properties.Lineage); lineage != "" {