def METHOD_NAME(bin, execPath, root):
	global qtPath
	otoolOutput = subprocess.check_output([otool, '-L', bin])
	toUpdate = []
	for line in otoolOutput.split('\n'):
		oldPath, newPath, oldExecPath, newExecPath = parseOtoolLine(line, execPath, root)
		if not newPath:
			continue
		if os.access(newPath, os.F_OK):
			if verbose:
				print('Skipping copying {}, already done.'.format(oldPath))
			newPath = None
		elif os.path.abspath(oldPath) != os.path.abspath(newPath):
			if verbose:
				print('Copying {} to {}...'.format(oldPath, newPath))
			parent, child = os.path.split(newPath)
			makedirs(parent)
			shutil.copy2(oldPath, newPath)
			os.chmod(newPath, 0o644)
		toUpdate.append((newPath, oldExecPath, newExecPath))
		if not qtPath and 'Qt' in oldPath:
			qtPath = findQtPath(oldPath)
			if verbose:
				print('Found Qt path at {}.'.format(qtPath))
	args = [installNameTool]
	for path, oldExecPath, newExecPath in toUpdate:
		if path != bin:
			if path:
				METHOD_NAME(path, execPath, root)
			if verbose:
				print('Updating Mach-O load from {} to {}...'.format(oldExecPath, newExecPath))
			args.extend(['-change', oldExecPath, newExecPath])
		else:
			if verbose:
				print('Updating Mach-O id from {} to {}...'.format(oldExecPath, newExecPath))
			args.extend(['-id', newExecPath])
	args.append(bin)
	subprocess.check_call(args)