diff options
Diffstat (limited to 'apex/apex.go')
| -rw-r--r-- | apex/apex.go | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/apex/apex.go b/apex/apex.go index 7ac3bc8d4..1f0618750 100644 --- a/apex/apex.go +++ b/apex/apex.go @@ -158,8 +158,8 @@ type apexBundleProperties struct { // is 'image'. Payload_type *string - // The type of filesystem to use when the payload_type is 'image'. Either 'ext4' or 'f2fs'. - // Default 'ext4'. + // The type of filesystem to use when the payload_type is 'image'. Either 'ext4', 'f2fs' + // or 'erofs'. Default 'ext4'. Payload_fs_type *string // For telling the APEX to ignore special handling for system libraries such as bionic. @@ -348,7 +348,6 @@ type apexBundle struct { // Flags for special variants of APEX testApex bool vndkApex bool - artApex bool // Tells whether this variant of the APEX bundle is the primary one or not. Only the primary // one gets installed to the device. @@ -754,13 +753,6 @@ func (a *apexBundle) DepsMutator(ctx android.BottomUpMutatorContext) { ctx.AddFarVariationDependencies(commonVariation, fsTag, a.properties.Filesystems...) ctx.AddFarVariationDependencies(commonVariation, compatConfigTag, a.properties.Compat_configs...) - if a.artApex { - // With EMMA_INSTRUMENT_FRAMEWORK=true the ART boot image includes jacoco library. - if ctx.Config().IsEnvTrue("EMMA_INSTRUMENT_FRAMEWORK") { - ctx.AddFarVariationDependencies(commonVariation, javaLibTag, "jacocoagent") - } - } - // Marks that this APEX (in fact all the modules in it) has to be built with the given SDKs. // This field currently isn't used. // TODO(jiyong): consider dropping this feature @@ -1151,8 +1143,9 @@ const ( zipApexType = "zip" flattenedApexType = "flattened" - ext4FsType = "ext4" - f2fsFsType = "f2fs" + ext4FsType = "ext4" + f2fsFsType = "f2fs" + erofsFsType = "erofs" ) // The suffix for the output "file", not the module @@ -1625,6 +1618,7 @@ type fsType int const ( ext4 fsType = iota f2fs + erofs ) func (f fsType) string() string { @@ -1633,6 +1627,8 @@ func (f fsType) string() string { return ext4FsType case f2fs: return f2fsFsType + case erofs: + return erofsFsType default: panic(fmt.Errorf("unknown APEX payload type %d", f)) } @@ -1679,6 +1675,9 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) { if _, ok := depTag.(android.ExcludeFromApexContentsTag); ok { return false } + if mod, ok := child.(android.Module); ok && !mod.Enabled() { + return false + } depName := ctx.OtherModuleName(child) if _, isDirectDep := parent.(*apexBundle); isDirectDep { switch depTag { @@ -2056,8 +2055,10 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) { a.payloadFsType = ext4 case f2fsFsType: a.payloadFsType = f2fs + case erofsFsType: + a.payloadFsType = erofs default: - ctx.PropertyErrorf("payload_fs_type", "%q is not a valid filesystem for apex [ext4, f2fs]", *a.properties.Payload_fs_type) + ctx.PropertyErrorf("payload_fs_type", "%q is not a valid filesystem for apex [ext4, f2fs, erofs]", *a.properties.Payload_fs_type) } // Optimization. If we are building bundled APEX, for the files that are gathered due to the @@ -2194,10 +2195,9 @@ func newApexBundle() *apexBundle { return module } -func ApexBundleFactory(testApex bool, artApex bool) android.Module { +func ApexBundleFactory(testApex bool) android.Module { bundle := newApexBundle() bundle.testApex = testApex - bundle.artApex = artApex return bundle } |