import re

def repl(m):
	res = "{}{}".format(re.escape(m.group(1)), m.group(2).replace("*", ".*").replace("?", "."))
	if m.group(3):
		res += re.escape(m.group(3))
	return res

def glob_to_regex(glob):
	glob = re.sub(r'\*{2,}', '*', glob)
	return '(?s)' + re.sub(r'([^?*]*)([*?]+)([^?*]+$)?', repl , glob)

l = ['baab', 'abbb', 'fc', 'AA', 'abb.']
print([x for x in l if re.search(glob_to_regex('?b*b'), x)])
print([x for x in l if re.search(glob_to_regex('?b*.'), x)])