summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--aconfig/codegen/init.go3
-rw-r--r--aconfig/codegen/java_aconfig_library.go5
-rw-r--r--apex/apex.go12
-rw-r--r--apex/apex_test.go1
-rw-r--r--apex/builder.go12
-rw-r--r--java/testing.go1
6 files changed, 7 insertions, 27 deletions
diff --git a/aconfig/codegen/init.go b/aconfig/codegen/init.go
index 98d288f0a..ed0b3ed7f 100644
--- a/aconfig/codegen/init.go
+++ b/aconfig/codegen/init.go
@@ -32,6 +32,7 @@ var (
` --mode ${mode}` +
` --cache ${in}` +
` --out ${out}.tmp` +
+ ` --allow-instrumentation ${debug}` +
` && $soong_zip -write_if_changed -jar -o ${out} -C ${out}.tmp -D ${out}.tmp` +
` && rm -rf ${out}.tmp`,
CommandDeps: []string{
@@ -39,7 +40,7 @@ var (
"$soong_zip",
},
Restat: true,
- }, "mode")
+ }, "mode", "debug")
// For cc_aconfig_library: Generate C++ library
cppRule = pctx.AndroidStaticRule("cc_aconfig_library",
diff --git a/aconfig/codegen/java_aconfig_library.go b/aconfig/codegen/java_aconfig_library.go
index 673ac2afe..ebca4134c 100644
--- a/aconfig/codegen/java_aconfig_library.go
+++ b/aconfig/codegen/java_aconfig_library.go
@@ -20,6 +20,7 @@ import (
"github.com/google/blueprint"
"github.com/google/blueprint/proptools"
+ "strconv"
)
type declarationsTagType struct {
@@ -71,6 +72,7 @@ func (callbacks *JavaAconfigDeclarationsLibraryCallbacks) DepsMutator(module *ja
module.AddSharedLibrary("aconfig-annotations-lib")
// TODO(b/303773055): Remove the annotation after access issue is resolved.
module.AddSharedLibrary("unsupportedappusage")
+ module.AddSharedLibrary("aconfig_storage_reader_java")
}
}
@@ -102,7 +104,8 @@ func (callbacks *JavaAconfigDeclarationsLibraryCallbacks) GenerateSourceJarBuild
Output: srcJarPath,
Description: "aconfig.srcjar",
Args: map[string]string{
- "mode": mode,
+ "mode": mode,
+ "debug": strconv.FormatBool(ctx.Config().ReleaseReadFromNewStorage()),
},
})
diff --git a/apex/apex.go b/apex/apex.go
index fc0500aec..04fd1813c 100644
--- a/apex/apex.go
+++ b/apex/apex.go
@@ -158,9 +158,6 @@ type apexBundleProperties struct {
// Default: true.
Installable *bool
- // Deprecated. Do not use. TODO(b/350644693) remove this after removing all usage
- Use_vndk_as_stable *bool
-
// The type of filesystem to use. Either 'ext4', 'f2fs' or 'erofs'. Default 'ext4'.
Payload_fs_type *string
@@ -168,10 +165,6 @@ type apexBundleProperties struct {
// Default is false.
Ignore_system_library_special_case *bool
- // Whenever apex_payload.img of the APEX should include dm-verity hashtree.
- // Default value is true.
- Generate_hashtree *bool
-
// Whenever apex_payload.img of the APEX should not be dm-verity signed. Should be only
// used in tests.
Test_only_unsigned_payload *bool
@@ -1428,11 +1421,6 @@ func (a *apexBundle) installable() bool {
return !a.properties.PreventInstall && (a.properties.Installable == nil || proptools.Bool(a.properties.Installable))
}
-// See the generate_hashtree property
-func (a *apexBundle) shouldGenerateHashtree() bool {
- return proptools.BoolDefault(a.properties.Generate_hashtree, true)
-}
-
// See the test_only_unsigned_payload property
func (a *apexBundle) testOnlyShouldSkipPayloadSign() bool {
return proptools.Bool(a.properties.Test_only_unsigned_payload)
diff --git a/apex/apex_test.go b/apex/apex_test.go
index 261d2ce59..915ac92f6 100644
--- a/apex/apex_test.go
+++ b/apex/apex_test.go
@@ -7026,7 +7026,6 @@ func TestLegacyAndroid10Support(t *testing.T) {
module := ctx.ModuleForTests("myapex", "android_common_myapex")
args := module.Rule("apexRule").Args
ensureContains(t, args["opt_flags"], "--manifest_json "+module.Output("apex_manifest.json").Output.String())
- ensureNotContains(t, args["opt_flags"], "--no_hashtree")
// The copies of the libraries in the apex should have one more dependency than
// the ones outside the apex, namely the unwinder. Ideally we should check
diff --git a/apex/builder.go b/apex/builder.go
index bfe16922d..e75ab0e55 100644
--- a/apex/builder.go
+++ b/apex/builder.go
@@ -767,18 +767,6 @@ func (a *apexBundle) buildApex(ctx android.ModuleContext) {
implicitInputs = append(implicitInputs, noticeAssetPath)
optFlags = append(optFlags, "--assets_dir "+filepath.Dir(noticeAssetPath.String()))
- // Apexes which are supposed to be installed in builtin dirs(/system, etc)
- // don't need hashtree for activation. Therefore, by removing hashtree from
- // apex bundle (filesystem image in it, to be specific), we can save storage.
- needHashTree := moduleMinSdkVersion.LessThanOrEqualTo(android.SdkVersion_Android10) ||
- a.shouldGenerateHashtree()
- if ctx.Config().ApexCompressionEnabled() && a.isCompressable() {
- needHashTree = true
- }
- if !needHashTree {
- optFlags = append(optFlags, "--no_hashtree")
- }
-
if a.testOnlyShouldSkipPayloadSign() {
optFlags = append(optFlags, "--unsigned_payload")
}
diff --git a/java/testing.go b/java/testing.go
index 7a42e4cce..445e096e6 100644
--- a/java/testing.go
+++ b/java/testing.go
@@ -424,6 +424,7 @@ func gatherRequiredDepsForTest() string {
"stub-annotations",
"aconfig-annotations-lib",
+ "aconfig_storage_reader_java",
"unsupportedappusage",
}