<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _spec_to_globs(address_mapper, specs):
 """Given a Specs object, return a PathGlobs object for the build files that it matches."""

  patterns = set()
  for spec in specs:
    patterns.update(spec.make_glob_patterns(address_mapper))
  return PathGlobs(include=patterns, exclude=address_mapper.build_ignore_patterns)