Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9814ff11 authored by Cole Faust's avatar Cole Faust
Browse files

Remove requirement that fsv_meta file is next to its input file

In soong-built partitions, we will generate fsv_meta files before
a partition staging directory is generated. This means that the source
file will be some module-specific intermediates path, and the dest
file will be a path local to the filesystem module. Relax the
requirement that fsv_meta files are next to the files they protect.

Bug: 394404628
Test: m aosp_shared_system_image, verified it didn't change before/after
Change-Id: I6bbbd23aa93b15220c5b2302cb0b229e8f8de69c
parent acd8beb0
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -230,12 +230,6 @@ if __name__ == '__main__':
  if not output_file:
    output_file = input_file + '.fsv_meta'

  if output_file != args.input + '.fsv_meta':
    sys.exit('When generating .fsv_meta files for symlinks, we assume that all fsv_meta files '
      'are named the same as the file they protect, just with the .fsv_meta suffix appended. '
      'We require that all .fsv_meta files follow this convention regardless of if it\'s a link or '
      'not. However {args.input} had a different output file: {args.output}')

  # remove the output file first, as switching between a file and a symlink can be complicated
  try:
    os.remove(output_file)