(self, output_filename, makefile_path, targets, build_dir)
Write a "sub-project" Makefile.

    This is a small, wrapper Makefile that calls the top-level Makefile to build
    the targets from a single gyp file (i.e. a sub-project).

    Arguments:
      output_filename: sub-project Makefile name to write
      makefile_path: path to the top-level Makefile
      targets: list of "all" targets for this sub-project
      build_dir: build output directory, relative to the sub-project
Write a "sub-project" Makefile.
Write a sub - project Makefile .
def WriteSubMake(self, output_filename, makefile_path, targets, build_dir):
    """Write a "sub-project" Makefile.

    This is a small, wrapper Makefile that calls the top-level Makefile to build
    the targets from a single gyp file (i.e. a sub-project).

    Arguments:
      output_filename: sub-project Makefile name to write
      makefile_path: path to the top-level Makefile
      targets: list of "all" targets for this sub-project
      build_dir: build output directory, relative to the sub-project
    """
    gyp.common.EnsureDirExists(output_filename)
    self.fp = open(output_filename, 'w')
    self.fp.write(header)
    # For consistency with other builders, put sub-project build output in the
    # sub-project dir (see test/subdirectory/gyptest-subdir-all.py).
    self.WriteLn('export builddir_name ?= %s' %
                 os.path.join(os.path.dirname(output_filename), build_dir))
    self.WriteLn('.PHONY: all')
    self.WriteLn('all:')
    if makefile_path:
      makefile_path = ' -C ' + makefile_path
    self.WriteLn('\t$(MAKE)%s %s' % (makefile_path, ' '.join(targets)))
    self.fp.close()
def WriteSubMake ( self , output_filename , makefile_path , targets , build_dir ) : gyp . common . EnsureDirExists ( output_filename ) self . fp = open ( output_filename , 'w' ) self . fp . write ( header ) # For consistency with other builders, put sub-project build output in the # sub-project dir (see test/subdirectory/gyptest-subdir-all.py). self . WriteLn ( 'export builddir_name ?= %s' % os . path . join ( os . path . dirname ( output_filename ) , build_dir ) ) self . WriteLn ( '.PHONY: all' ) self . WriteLn ( 'all:' ) if makefile_path : makefile_path = ' -C ' + makefile_path self . WriteLn ( '\t$(MAKE)%s %s' % ( makefile_path , ' ' . join ( targets ) ) ) self . fp . close ( )