def METHOD_NAME(argv):
  parser = argparse.ArgumentParser()
  # parser.add_argument('-g', '--header', type=str, default=None,
  #   help='Output header file (default: none)')
  parser.add_argument('--cd', type=str, default='.',
    help='CD to the given directory before listing files.')
  parser.add_argument('-c', '--compress', default='none',
    choices=['gzip', 'bz2', 'xz', 'none'],
    help='Compress the data before exporting it')
  parser.add_argument('-a', '--array', type=str, default=None, metavar='name',
    help='If set this will generate an array of included resources and their names')
  parser.add_argument('-s', '--scaled', type=str, action='append', metavar='path', default=[],
    help='For each file specified here, bin2c will search for versions of the file with @2, @3, @4, etc. '
      + 'before the extension. These will all be added as resources.')
  parser.add_argument('output_file', type=str,
    help='Output C/C++ file')
  parser.add_argument('output_header', type=str,
    help='Output header file')
  parser.add_argument('inputs', type=str, nargs='*',
    metavar='file_name data_name',
    help='Pairs of input file names and C array names')
  args = parser.parse_args(argv)
  os.chdir(args.cd)
  inputs = args.inputs
  if len(inputs) % 2 != 0:
    raise Exception('Invalid number of input arguments, must be multiple of 2')
  entries = []
  def add_entry(path, name):
    pt = os.path.relpath(path).replace('\\', '/')
    with open(pt, 'rb') as fd:
      data_in = fd.read()
    data = compress(args.compress, data_in)
    entries.append(Entry(pt, data, make_cname(name)))
  # Process our normal args
  for i in range(0, len(inputs), 2):
    add_entry(inputs[i+0], inputs[i+1])
  # Process scaled arguments
  for pt in args.scaled:
    dir, fname = os.path.split(pt)
    froot, fext = os.path.splitext(fname)
    if dir == '':
      dir = '.'
    # Find all files that match the given file name format
    for fn in os.listdir(dir):
      if fn.startswith(froot) and fn.endswith(fext):
        m = SCALE_SIZE_PATTERN.match(fn[len(froot):-len(fext)])
        # If it's a scaled file or the current file, add it
        if m or fn == fname:
          add_entry(fn, fn)
  # end process scaled arguments
  process(entries, args.output_file, args.output_header, args.array)