def delete_command(lc, options = {})
      @raw_data.slice!(lc.view.offset, lc.cmdsize)

      # update Mach-O header fields to account for deleted load command
      update_ncmds(ncmds - 1)
      update_sizeofcmds(sizeofcmds - lc.cmdsize)

      # pad the space after the load commands to preserve offsets
      @raw_data.insert(header.class.bytesize + sizeofcmds - lc.cmdsize, Utils.nullpad(lc.cmdsize))

      populate_fields if options.fetch(:repopulate, true)
    end
def delete_command(lc, options = {})
      @raw_data.slice!(lc.view.offset, lc.cmdsize)

      # update Mach-O header fields to account for deleted load command
      update_ncmds(ncmds - 1)
      update_sizeofcmds(sizeofcmds - lc.cmdsize)

      # pad the space after the load commands to preserve offsets
      @raw_data.insert(header.class.bytesize + sizeofcmds - lc.cmdsize, Utils.nullpad(lc.cmdsize))

      populate_fields if options.fetch(:repopulate, true)
    end
Delete a load command from the Mach-O.
 @param lc [LoadCommands::LoadCommand] the load command being deleted
 @param options [Hash]
 @option options [Boolean] :repopulate (true) whether or not to repopulate
  the instance fields
 @return [void]
 @note This is public, but methods like {#delete_rpath} should be preferred.
  Setting `repopulate` to false **will leave the instance in an
  inconsistent state** unless {#populate_fields} is called **immediately**
  afterwards.