Merge "Revert "Fix retrofit OTA generation failures"" into main
diff --git a/tools/releasetools/ota_utils.py b/tools/releasetools/ota_utils.py
index 27364d0..048a497 100644
--- a/tools/releasetools/ota_utils.py
+++ b/tools/releasetools/ota_utils.py
@@ -1111,8 +1111,9 @@
relative_path = path.removeprefix(input_dir).removeprefix("/")
if not Fnmatch(relative_path, UNZIP_PATTERN):
continue
- target_path = os.path.join(
- output_dir, relative_path)
- os.makedirs(os.path.dirname(target_path), exist_ok=True)
- shutil.copy(path, target_path)
+ if filename.endswith(".prop") or filename == "prop.default" or "/etc/vintf/" in relative_path:
+ target_path = os.path.join(
+ output_dir, relative_path)
+ os.makedirs(os.path.dirname(target_path), exist_ok=True)
+ shutil.copy(path, target_path)
return output_dir