Example #1
0
File: Build.py Project: zsx/waf
	def __call__(self, *k, **kw):
		"""Creates a task generator"""
		kw['bld'] = self
		ret = TaskGen.task_gen(*k, **kw)
		self.task_gen_cache_names = {} # reset the cache, each time
		self.add_to_group(ret, group=kw.get('group', None))
		return ret
Example #2
0
 def __call__(self, *k, **kw):
     # this is one way of doing it, one could use a task generator method too
     bld = kw['bld'] = bld_proxy(self)
     ret = TaskGen.task_gen(*k, **kw)
     self.task_gen_cache_names = {}
     self.add_to_group(ret, group=kw.get('group'))
     ret.bld = bld
     bld.set_key(ret.path.abspath().replace(os.sep, '') + str(ret.idx))
     return ret
Example #3
0
	def __call__(self, *k, **kw):
		# this is one way of doing it, one could use a task generator method too
		bld = kw['bld'] = bld_proxy(self)
		ret = TaskGen.task_gen(*k, **kw)
		self.task_gen_cache_names = {}
		self.add_to_group(ret, group=kw.get('group'))
		ret.bld = bld
		bld.set_key(ret.path.abspath().replace(os.sep, '') + str(ret.idx))
		return ret
Example #4
0
File: Build.py Project: SjB/waf
	def __call__(self, *k, **kw):
		"""
		Create a task generator, adding it to the current build group. The following forms are equivalent::

			def build(bld):
				tg = bld(a=1, b=2)

			def build(bld):
				tg = bld()
				tg.a = 1
				tg.b = 2
		"""
		kw['bld'] = self
		ret = TaskGen.task_gen(*k, **kw)
		self.task_gen_cache_names = {} # reset the cache, each time
		self.add_to_group(ret, group=kw.get('group', None))
		return ret
Example #5
0
	def __call__(self, *k, **kw):
		"""
		Create a task generator and add it to the current build group. The following forms are equivalent::

			def build(bld):
				tg = bld(a=1, b=2)

			def build(bld):
				tg = bld()
				tg.a = 1
				tg.b = 2

			def build(bld):
				tg = TaskGen.task_gen(a=1, b=2)
				bld.add_to_group(tg, None)

		:param group: group name to add the task generator to
		:type group: string
		"""
		kw['bld'] = self
		ret = TaskGen.task_gen(*k, **kw)
		self.task_gen_cache_names = {} # reset the cache, each time
		self.add_to_group(ret, group=kw.get('group'))
		return ret
    def __call__(self, *k, **kw):
        """
		Create a task generator and add it to the current build group. The following forms are equivalent::

			def build(bld):
				tg = bld(a=1, b=2)

			def build(bld):
				tg = bld()
				tg.a = 1
				tg.b = 2

			def build(bld):
				tg = TaskGen.task_gen(a=1, b=2)
				bld.add_to_group(tg, None)

		:param group: group name to add the task generator to
		:type group: string
		"""
        kw['bld'] = self
        ret = TaskGen.task_gen(*k, **kw)
        self.task_gen_cache_names = {}  # reset the cache, each time
        self.add_to_group(ret, group=kw.get('group'))
        return ret
Example #7
0
 def __call__(self, *k, **kw):
     kw["bld"] = self
     ret = TaskGen.task_gen(*k, **kw)
     self.task_gen_cache_names = {}
     self.add_to_group(ret, group=kw.get("group", None))
     return ret
Example #8
0
 def __call__(self, *k, **kw):
     kw['bld'] = self
     ret = TaskGen.task_gen(*k, **kw)
     self.task_gen_cache_names = {}
     self.add_to_group(ret, group=kw.get('group', None))
     return ret
Example #9
0
	def __call__(self,*k,**kw):
		kw['bld']=self
		ret=TaskGen.task_gen(*k,**kw)
		self.task_gen_cache_names={}
		self.add_to_group(ret,group=kw.get('group'))
		return ret