convert globs to regexps, so patterns can match **