parameters: (self, outdir, macros, incdirs, sources, depends,
                         extra)
return_statement: return macros, objects, extra, pp_opts, build
docstring: Process arguments and decide which source files to compile.
docstring_summary: Process arguments and decide which source files to compile.
docstring_tokens: Process arguments and decide which source files to compile .
function: def _setup_compile(self, outdir, macros, incdirs, sources, depends,
                         extra):
          """Process arguments and decide which source files to compile."""
          if outdir is None:
              outdir = self.output_dir
          elif not isinstance(outdir, str):
              raise TypeError, "'output_dir' must be a string or None"
  
          if macros is None:
              macros = self.macros
          elif isinstance(macros, list):
              macros = macros + (self.macros or [])
          else:
              raise TypeError, "'macros' (if supplied) must be a list of tuples"
  
          if incdirs is None:
              incdirs = self.include_dirs
          elif isinstance(incdirs, (list, tuple)):
              incdirs = list(incdirs) + (self.include_dirs or [])
          else:
              raise TypeError, \
                    "'include_dirs' (if supplied) must be a list of strings"
  
          if extra is None:
              extra = []
  
          # Get the list of expected output (object) files
          objects = self.object_filenames(sources,
                                          strip_dir=0,
                                          output_dir=outdir)
          assert len(objects) == len(sources)
  
          pp_opts = gen_preprocess_options(macros, incdirs)
  
          build = {}
          for i in range(len(sources)):
              src = sources[i]
              obj = objects[i]
              ext = os.path.splitext(src)[1]
              self.mkpath(os.path.dirname(obj))
              build[obj] = (src, ext)
  
          return macros, objects, extra, pp_opts, build
function_tokens: def _setup_compile ( self , outdir , macros , incdirs , sources , depends , extra ) : if outdir is None : outdir = self . output_dir elif not isinstance ( outdir , str ) : raise TypeError , "'output_dir' must be a string or None" if macros is None : macros = self . macros elif isinstance ( macros , list ) : macros = macros + ( self . macros or [ ] ) else : raise TypeError , "'macros' (if supplied) must be a list of tuples" if incdirs is None : incdirs = self . include_dirs elif isinstance ( incdirs , ( list , tuple ) ) : incdirs = list ( incdirs ) + ( self . include_dirs or [ ] ) else : raise TypeError , "'include_dirs' (if supplied) must be a list of strings" if extra is None : extra = [ ] # Get the list of expected output (object) files objects = self . object_filenames ( sources , strip_dir = 0 , output_dir = outdir ) assert len ( objects ) == len ( sources ) pp_opts = gen_preprocess_options ( macros , incdirs ) build = { } for i in range ( len ( sources ) ) : src = sources [ i ] obj = objects [ i ] ext = os . path . splitext ( src ) [ 1 ] self . mkpath ( os . path . dirname ( obj ) ) build [ obj ] = ( src , ext ) return macros , objects , extra , pp_opts , build