summaryrefslogtreecommitdiff
path: root/filesystem/filesystem.go
diff options
context:
space:
mode:
Diffstat (limited to 'filesystem/filesystem.go')
-rw-r--r--filesystem/filesystem.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/filesystem/filesystem.go b/filesystem/filesystem.go
index 6dfbfd1be..4027b9a79 100644
--- a/filesystem/filesystem.go
+++ b/filesystem/filesystem.go
@@ -600,6 +600,11 @@ func (f *filesystem) copyFilesToProductOut(ctx android.ModuleContext, builder *a
builder.Command().Textf("cp -prf %s/* %s", rebasedDir, installPath)
}
+func copyImageFileToProductOut(ctx android.ModuleContext, builder *android.RuleBuilder, partition string, output android.Path) {
+ copyDir := android.PathForModuleInPartitionInstall(ctx, "").Join(ctx, fmt.Sprintf("%s.img", partition))
+ builder.Command().Textf("rsync -a %s %s", output, copyDir)
+}
+
func (f *filesystem) rootDirString() string {
return f.partitionName()
}
@@ -651,6 +656,10 @@ func (f *filesystem) buildImageUsingBuildImage(ctx android.ModuleContext) (andro
Output(output).
Text(rootDir.String()) // directory where to find fs_config_files|dirs
+ if !ctx.Config().KatiEnabled() {
+ copyImageFileToProductOut(ctx, builder, f.partitionName(), output)
+ }
+
// rootDir is not deleted. Might be useful for quick inspection.
builder.Build("build_filesystem_image", fmt.Sprintf("Creating filesystem %s", f.BaseModuleName()))