Back to index

enigmail  1.4.3
Public Member Functions | Public Attributes
pymake.command._MakeContext Class Reference

List of all members.

Public Member Functions

def __init__
def remakecb
def makecb

Public Attributes

 makeflags
 makelevel
 workdir
 context
 env
 targets
 options
 ostmts
 overrides
 cb
 restarts
 makefile
 realtargets
 tstack

Detailed Description

Definition at line 75 of file command.py.


Constructor & Destructor Documentation

def pymake.command._MakeContext.__init__ (   self,
  makeflags,
  makelevel,
  workdir,
  context,
  env,
  targets,
  options,
  ostmts,
  overrides,
  cb 
)

Definition at line 76 of file command.py.

00076 
00077     def __init__(self, makeflags, makelevel, workdir, context, env, targets, options, ostmts, overrides, cb):
00078         self.makeflags = makeflags
00079         self.makelevel = makelevel
00080 
00081         self.workdir = workdir
00082         self.context = context
00083         self.env = env
00084         self.targets = targets
00085         self.options = options
00086         self.ostmts = ostmts
00087         self.overrides = overrides
00088         self.cb = cb
00089 
00090         self.restarts = 0
00091 
00092         self.remakecb(True)


Member Function Documentation

def pymake.command._MakeContext.makecb (   self,
  error,
  didanything 
)

Definition at line 145 of file command.py.

00145 
00146     def makecb(self, error, didanything):
00147         assert error in (True, False)
00148 
00149         if error:
00150             self.context.defer(self.cb, 2)
00151             return
00152 
00153         if not len(self.realtargets):
00154             if self.options.printdir:
00155                 print "make.py[%i]: Leaving directory '%s'" % (self.makelevel, self.workdir)
00156             sys.stdout.flush()
00157 
00158             self.context.defer(self.cb, 0)
00159         else:
00160             self.makefile.gettarget(self.realtargets.pop(0)).make(self.makefile, self.tstack, self.makecb)

Here is the call graph for this function:

Here is the caller graph for this function:

def pymake.command._MakeContext.remakecb (   self,
  remade,
  error = None 
)

Definition at line 93 of file command.py.

00093 
00094     def remakecb(self, remade, error=None):
00095         if error is not None:
00096             print error
00097             self.context.defer(self.cb, 2)
00098             return
00099 
00100         if remade:
00101             if self.restarts > 0:
00102                 _log.info("make.py[%i]: Restarting makefile parsing", self.makelevel)
00103 
00104             self.makefile = data.Makefile(restarts=self.restarts,
00105                                           make='%s %s' % (sys.executable.replace('\\', '/'), makepypath.replace('\\', '/')),
00106                                           makeflags=self.makeflags,
00107                                           makeoverrides=self.overrides,
00108                                           workdir=self.workdir,
00109                                           context=self.context,
00110                                           env=self.env,
00111                                           makelevel=self.makelevel,
00112                                           targets=self.targets,
00113                                           keepgoing=self.options.keepgoing,
00114                                           silent=self.options.silent,
00115                                           justprint=self.options.justprint)
00116 
00117             self.restarts += 1
00118 
00119             try:
00120                 self.ostmts.execute(self.makefile)
00121                 for f in self.options.makefiles:
00122                     self.makefile.include(f)
00123                 self.makefile.finishparsing()
00124                 self.makefile.remakemakefiles(self.remakecb)
00125             except util.MakeError, e:
00126                 print e
00127                 self.context.defer(self.cb, 2)
00128 
00129             return
00130 
00131         if len(self.targets) == 0:
00132             if self.makefile.defaulttarget is None:
00133                 print "No target specified and no default target found."
00134                 self.context.defer(self.cb, 2)
00135                 return
00136 
00137             _log.info("Making default target %s", self.makefile.defaulttarget)
00138             self.realtargets = [self.makefile.defaulttarget]
00139             self.tstack = ['<default-target>']
00140         else:
00141             self.realtargets = self.targets
00142             self.tstack = ['<command-line>']
00143 
00144         self.makefile.gettarget(self.realtargets.pop(0)).make(self.makefile, self.tstack, cb=self.makecb)


Member Data Documentation

Definition at line 87 of file command.py.

Definition at line 81 of file command.py.

Definition at line 82 of file command.py.

Definition at line 103 of file command.py.

Definition at line 77 of file command.py.

Definition at line 78 of file command.py.

Definition at line 84 of file command.py.

Definition at line 85 of file command.py.

Definition at line 86 of file command.py.

Definition at line 137 of file command.py.

Definition at line 89 of file command.py.

Definition at line 83 of file command.py.

Definition at line 138 of file command.py.

Definition at line 80 of file command.py.


The documentation for this class was generated from the following file: