summaryrefslogtreecommitdiffstats
path: root/tools/releasetools
diff options
context:
space:
mode:
authorYing Wang <wangying@google.com>2010-11-17 17:45:36 -0800
committerYing Wang <wangying@google.com>2010-11-17 17:45:36 -0800
commitc5a07ce038d7aeb62a5c02886cd2ecbf56687e9d (patch)
tree042efdec247cf93da9c6756ffbd071b667182bfd /tools/releasetools
parent7ca5c913890ce16be32ecf3361f3b7fd995e3cbe (diff)
downloadbuild-c5a07ce038d7aeb62a5c02886cd2ecbf56687e9d.zip
build-c5a07ce038d7aeb62a5c02886cd2ecbf56687e9d.tar.gz
build-c5a07ce038d7aeb62a5c02886cd2ecbf56687e9d.tar.bz2
Pass extfs sparse image flag to the release tool.
Change-Id: Icb2a1c4fddb2b6153298ba1b849016aa3d792773
Diffstat (limited to 'tools/releasetools')
-rwxr-xr-xtools/releasetools/img_from_target_files17
1 files changed, 11 insertions, 6 deletions
diff --git a/tools/releasetools/img_from_target_files b/tools/releasetools/img_from_target_files
index 488226f..793f7ac 100755
--- a/tools/releasetools/img_from_target_files
+++ b/tools/releasetools/img_from_target_files
@@ -63,9 +63,11 @@ def AddUserdata(output_zip):
build_command = []
fstab = OPTIONS.info_dict["fstab"]
if fstab and fstab["/data"].fs_type.startswith("ext"):
- build_command = ["mkuserimg.sh",
- user_dir, img.name,
- fstab["/data"].fs_type, "data"]
+ build_command = ["mkuserimg.sh"]
+ if "extfs_sparse_flag" in OPTIONS.info_dict:
+ build_command.append(OPTIONS.info_dict["extfs_sparse_flag"])
+ build_command.extend([user_dir, img.name,
+ fstab["/data"].fs_type, "data"])
if "userdata_size" in OPTIONS.info_dict:
build_command.append(str(OPTIONS.info_dict["userdata_size"]))
else:
@@ -112,9 +114,12 @@ def AddSystem(output_zip):
build_command = []
fstab = OPTIONS.info_dict["fstab"]
if fstab and fstab["/system"].fs_type.startswith("ext"):
- build_command = ["mkuserimg.sh",
- os.path.join(OPTIONS.input_tmp, "system"), img.name,
- fstab["/system"].fs_type, "system"]
+
+ build_command = ["mkuserimg.sh"]
+ if "extfs_sparse_flag" in OPTIONS.info_dict:
+ build_command.append(OPTIONS.info_dict["extfs_sparse_flag"])
+ build_command.extend([os.path.join(OPTIONS.input_tmp, "system"), img.name,
+ fstab["/system"].fs_type, "system"])
if "system_size" in OPTIONS.info_dict:
build_command.append(str(OPTIONS.info_dict["system_size"]))
else: