• Home
  • Raw
  • Download

Lines Matching +full:build +full:- +full:args

3 # Use of this source code is governed by a BSD-style license that can be
19 Computes the new build-id from old build-id and file_path.
21 Args:
22 old_build_id: Original build-id in bytearray.
26 New build id with the same length as |old_build_id|.
30 m.update(os.path.basename(file_path).encode('utf-8'))
44 the .note.gnu.build-id section so that the build-id remains
48 - `objcopy` does not modify build-id when partitioning the
50 - The new build-id is calculated as hash of original build-id
53 Args:
61 # We do not overwrite build-id on main partition to allow the expected
62 # partition build ids to be synthesized given a libchrome.so binary,
65 [objcopy, '--extract-main-partition', input_elf, output_elf])
69 build_id_section = '.note.gnu.build-id'
76 # Dump out build-id section and remove original build-id section from
80 '--extract-partition',
82 # Note: Not using '--update-section' here as it is not supported
83 # by llvm-objcopy.
84 '--remove-section',
86 '--dump-section',
102 # `build-id` rewrite is only required on Android platform,
104 # Android platform uses little-endian.
105 # <: little-endian
109 prefix = note_content[:-descsz]
110 build_id = note_content[-descsz:]
115 # Write back the new build-id section.
118 '--add-section',
121 # objcopy --strip-all when generating unstripped lib file.
122 '--set-section-flags',
132 '--partition',
136 '--objcopy',
138 help='Path to llvm-objcopy binary',
141 '--unstripped-output',
146 '--stripped-output',
150 parser.add_argument('--split-dwarf', action='store_true')
152 args = parser.parse_args()
154 _ExtractPartition(args.objcopy, args.input, args.unstripped_output,
155 args.partition)
157 args.objcopy,
158 '--strip-all',
159 args.unstripped_output,
160 args.stripped_output,
165 if args.split_dwarf:
166 dest = args.unstripped_output + '.dwp'
171 relpath = os.path.relpath(args.input + '.dwp', os.path.dirname(dest))