build_image: check value of "ext4_share_dup_blocks"

Regardless of the value of "ext4_share_dup_blocks" "-c" flag is passed
unconditionally. The correct behavior is to check if
"ext4_share_dup_blocks" is set to "true".

Test: 1. build bonito with "BOARD_EXT4_SHARE_DUP_BLOCKS := false"
      2. check for "shared_blocks" feature of system.img
         ./out/host/linux-x86/bin/tune2fs -l \
         ./out/target/product/bonito/system.img | \
         grep -o shared_blocks

Change-Id: I8c0e5606658dd0f47b71cfc6c453a77a57da4f42
This commit is contained in:
Tamas Petz 2020-02-03 15:41:02 +01:00
parent 1dffdf84d1
commit c0a8c63935
1 changed files with 1 additions and 1 deletions

View File

@ -287,7 +287,7 @@ def BuildImageMkfs(in_dir, prop_dict, out_file, target_out, fs_config):
build_command.extend(["-U", prop_dict["uuid"]])
if "hash_seed" in prop_dict:
build_command.extend(["-S", prop_dict["hash_seed"]])
if "ext4_share_dup_blocks" in prop_dict:
if prop_dict.get("ext4_share_dup_blocks") == "true":
build_command.append("-c")
if (needs_projid):
build_command.extend(["--inode_size", "512"])