ó
Æ^c           @   sD  d  Z  d d l Z d d l Z d d l Z d d l Z d d l Z d d l Z y d d l Z Wn e k
 r} d d l	 Z n Xd d l
 m Z m Z m Z m Z m Z m Z m Z m Z m Z m Z d Z d Z d Z d Z d j ƒ  Z d	 Z d
 Z d Z d Z e j d k rd
 Z n  d e j f d „  ƒ  YZ  e j! d ƒ e j" d d ƒ d „  ƒ ƒ Z# e j$ d „  ƒ Z% e j$ d „  ƒ Z& e j$ d „  ƒ Z' e j$ d „  ƒ Z( d e j f d „  ƒ  YZ) d e  f d „  ƒ  YZ* d e* f d „  ƒ  YZ+ d e  f d „  ƒ  YZ, d e  f d  „  ƒ  YZ- d! e  f d" „  ƒ  YZ. d# e  f d$ „  ƒ  YZ/ d S(%   sp   
Classes related to the build phase (build, clean, install, step, etc)

The inheritance tree is the following:

iÿÿÿÿN(
   t   Nodet   Runnert   TaskGent   Utilst	   ConfigSett   Taskt   Logst   Optionst   Contextt   Errorst   c4ches	   _cache.pyi9  iÇúÿÿs4   root node_sigs task_sigs imp_sigs raw_deps node_depst	   cfg_filesi    i   t   clit   BuildContextc           B   s¯  e  Z d  Z d Z d Z d „  Z d „  Z e e d+ ƒ Z	 d „  Z
 d „  Z d „  Z d „  Z d	 „  Z d
 „  Z d „  Z d „  Z d „  Z d „  Z d+ d+ d „ Z d „  Z d „  Z e e e ƒ Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z  d „  Z! d „  Z" d+ d „ Z# d „  Z$ d „  Z% d+ e& d  „ Z' d! „  Z( d" „  Z) d# „  Z* d$ „  Z+ d% „  Z, d& „  Z- d' „  Z. d( „  Z/ d) „  Z0 d* „  Z1 RS(,   s   executes the buildt   buildt    c         K   s”  t  t |  ƒ j | �  d |  _ | j d t j ƒ |  _ | j d t j ƒ |  _ | j d t j ƒ |  _ t j	 |  _	 t
 |  _ | j d ƒ |  _ |  j sµ t j j |  j t ƒ |  _ n  i  |  _ i  |  _ i  |  _ i  |  _ i  |  _ i  |  _ i  |  _ t j j |  _ t j j |  _ t j j |  _ t j j |  _ t j t  ƒ |  _! d |  _" g  |  _# i  |  _$ x0 t% D]( } t& |  | ƒ sdt' |  | i  ƒ qdqdWd  S(   Ni    t   top_dirt   out_dirt   run_dirt	   cache_dir((   t   superR   t   __init__t
   is_installt   getR   R   R   R   t
   launch_dirt	   POST_LAZYt	   post_modeR   t   ost   patht   joint	   CACHE_DIRt   all_envst	   node_sigst	   task_sigst   imp_sigst	   node_depst   raw_depst   task_gen_cache_namesR   t   optionst   jobst   targetst   keept   progress_barR   t   defaultdictt   listt   deps_mant   current_groupt   groupst   group_namest   SAVED_ATTRSt   hasattrt   setattr(   t   selft   kwt   v(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR   7   s8    													c         C   s5   |  j  s |  j St j j |  j t j j |  j  ƒ ƒ S(   s$   Getter for the variant_dir attribute(   t   variantR   R   R   R   t   normpath(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_variant_dir’   s    	c         O   sE   |  | d <t  j | | Ž  } i  |  _ |  j | d | j d ƒ ƒ| S(   sw  
		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
		t   bldt   group(   R   t   task_genR%   t   add_to_groupR   (   R4   t   kR5   t   ret(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   __call__™   s
    
	c         C   s   t  j d ƒ ‚ d S(   sT   
		Build contexts cannot be copied

		:raises: :py:class:`waflib.Errors.WafError`
		s   build contexts cannot be copiedN(   R	   t   WafError(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   __copy__²   s    c         C   s  |  j  j |  j ƒ } | s- t j d ƒ ‚ n  | j d t d t ƒ} | s^ t j d ƒ ‚ n  x¨ | D]  } | j | ƒ j	 t d ƒ j	 d d ƒ } t
 j
 | j ƒ  ƒ } | |  j | <xN | t D]B } |  j  j | ƒ } | së | j ƒ  r¿ t j d | ƒ ‚ q¿ q¿ Wqe Wd	 S(
   s  
		The configuration command creates files of the form ``build/c4che/NAMEcache.py``. This method
		creates a :py:class:`waflib.ConfigSet.ConfigSet` instance for each ``NAME`` by reading those
		files and stores them in :py:attr:`waflib.Build.BuildContext.allenvs`.
		s:   The project was not configured: run "waf configure" first!s   **/*%st   quiets5   The cache directory is empty: reconfigure the projectR   s   \t   /s7   Missing configuration file %r, reconfigure the project!N(   t   roott	   find_nodeR   R	   RA   t   ant_globt   CACHE_SUFFIXt   Truet	   path_fromt   replaceR   t   abspathR   t	   CFG_FILESt   find_resourcet   exists(   R4   t   nodet   lstt   xt   namet   envt   ft   newnode(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt	   load_envsº   s    'c         C   s„   t  j j |  j ƒ o' t  j j |  j ƒ s< t j d ƒ ‚ n  |  j j |  j ƒ |  _ |  _	 |  j j
 |  j ƒ |  _ |  j j ƒ  d S(   s*  
		Initialize the project directory and the build directory by creating the nodes
		:py:attr:`waflib.Build.BuildContext.srcnode` and :py:attr:`waflib.Build.BuildContext.bldnode`
		corresponding to ``top_dir`` and ``variant_dir`` respectively. The ``bldnode`` directory is
		created if necessary.
		s:   The project was not configured: run "waf configure" first!N(   R   R   t   isabsR   R   R	   RA   RE   t   find_dirt   srcnodet	   make_nodet   variant_dirt   bldnodet   mkdir(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt	   init_dirsÑ   s
    *c         C   s.   |  j  ƒ  |  j s  |  j ƒ  n  |  j ƒ  d S(   sŸ   
		Restore data from previous builds and call :py:meth:`waflib.Build.BuildContext.execute_build`.
		Overrides from :py:func:`waflib.Context.Context.execute`
		N(   t   restoreR   RW   t   execute_build(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   executeß   s    
	c      	   C   s*  t  j d |  j ƒ |  j |  j g ƒ |  j ƒ  t j ƒ  |  _ z |  j	 ƒ  Wd |  j
 d k rÞ t j j ƒ  rÞ |  j j p} d } |  j | | t  j j t  j j ƒ } t  j | d i t j d 6t  j j d 6t  j j d 6ƒn  t  j d |  j ƒ Xy d |  j _ |  ` Wn t k
 rn X|  j ƒ  d S(	   sc  
		Execute the build by:

		* reading the scripts (see :py:meth:`waflib.Context.Context.recurse`)
		* calling :py:meth:`waflib.Build.BuildContext.pre_build` to call user build functions
		* calling :py:meth:`waflib.Build.BuildContext.compile` to process the tasks
		* calling :py:meth:`waflib.Build.BuildContext.post_build` to call user build functions
		s   Waf: Entering directory `%s'Ni   t   extrat   streamt   c1t   c2s   Waf: Leaving directory `%s'(   R   t   infoR\   t   recurseR   t	   pre_buildR   t   Timert   timert   compileR*   t   syst   stderrt   isattyt   producert	   processedt   progress_linet   colorst   BLUEt   NORMALt
   cursor_offt	   cursor_ont   NoneR:   t   AttributeErrort
   post_build(   R4   t   ct   m(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRa   é   s"    

$:
c         C   s~  y% t  j  t j j |  j d ƒ ƒ } Wn t k
 r8 nF X| j t j k  r] t	 j
 d ƒ ‚ n  x | j D] } |  j | �  qg Wt j j |  j t j ƒ } y t j | d ƒ } Wn' t t f k
 rØ t j d | ƒ n˜ Xz† t j j ƒ  |  j t _ y t j | ƒ } Wn& t k
 r0} t j d | | ƒ n. Xx* t D]" } t |  | | j | i  ƒ ƒ q8WWd t j j ƒ  X|  j  ƒ  d S(   sg   
		Load data from a previous run, sets the attributes listed in :py:const:`waflib.Build.SAVED_ATTRS`
		s   build.config.pysM   Project was configured with a different version of Waf, please reconfigure itt   rbs2   build: Could not load the build cache %s (missing)s.   build: Could not pickle the build cache %s: %rN(!   R   R   R   R   R   t   EnvironmentErrort   versionR   t
   HEXVERSIONR	   RA   t   toolst   setupR\   t   DBFILER   t   readft   EOFErrorR   t   debugR    t   pickle_lockt   acquiret
   node_classt   Nod3t   cPicklet   loadst	   ExceptionR1   R3   R   t   releaseR_   (   R4   RT   t   tt   dbfnt   datat   eRR   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR`   	  s0    %$c         C   s  i  } x! t  D] } t |  | ƒ | | <q Wt j j |  j t j ƒ } z/ t j	 j
 ƒ  |  j t _ t j | t ƒ } Wd t j	 j ƒ  Xt j | d | d d ƒyI t j | ƒ } t j | ƒ t j sç t j | d | j | j ƒ n  Wn t t f k
 rn Xt j | d | ƒ d S(   s—   
		Store data for next runs, set the attributes listed in :py:const:`waflib.Build.SAVED_ATTRS`. Uses a temporary
		file to avoid problems on ctrl+c.
		Ns   .tmpR|   t   wb(   R1   t   getattrR   R   R   R\   R   Rƒ   R    R‡   Rˆ   R‰   RŠ   R‹   t   dumpst   PROTOCOLRŽ   R   t   writeft   statt   removet   is_win32t   chownt   st_uidt   st_gidRy   t   OSErrort   rename(   R4   R‘   RR   t   dbt   st(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   store.  s$    	$c         C   s¹   t  j d ƒ t j |  |  j ƒ |  _ |  j ƒ  |  j _ y |  j j ƒ  Wn- t	 k
 rw |  j
 ƒ  rq |  j ƒ  n  ‚  n X|  j
 ƒ  r‘ |  j ƒ  n  |  j j rµ t j |  j j ƒ ‚ n  d S(   sÙ   
		Run the build by creating an instance of :py:class:`waflib.Runner.Parallel`
		The cache file is written when at least a task was executed.

		:raises: :py:class:`waflib.Errors.BuildError` in case the build fails
		s   build: compile()N(   R   R†   R   t   ParallelR'   Rp   t   get_build_iteratort   bitert   startt   KeyboardInterruptt   is_dirtyR¢   t   errorR	   t
   BuildError(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRl   L  s    c         C   s
   |  j  j S(   N(   Rp   t   dirty(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR¨   e  s    c         C   si   t  | t ƒ r4 x | D] } |  j | | ƒ q Wd St j | | ƒ } t | d ƒ re | j |  ƒ n  d S(   sF  
		Import waf tools defined during the configuration::

			def configure(conf):
				conf.load('glib2')

			def build(bld):
				pass # glib2 is imported implicitly

		:param tool: tool list
		:type tool: list
		:param tooldir: optional tool directory (sys.path)
		:type tooldir: list of string
		:param funs: unused variable
		NR‚   (   t
   isinstanceR,   R‚   R   t	   load_toolR2   (   R4   t   toolt   tooldirt   funst   it   module(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR‚   h  s    c         C   s2   y |  j  |  j SWn t k
 r- |  j  d SXd S(   s   Getter for the env propertyR   N(   R   R7   t   KeyError(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_env�  s    c         C   s   | |  j  |  j <d S(   s   Setter for the env propertyN(   R   R7   (   R4   t   val(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   set_env‡  s    c         C   sÄ   | s t  d | ƒ ‚ n  t | t j ƒ r4 | } n9 t j j | ƒ r[ |  j j | ƒ } n |  j j | ƒ } | s† t  d | ƒ ‚ n  t | t ƒ r¬ |  j	 | j
 | ƒ n |  j	 | j | ƒ d S(   sŠ  
		Adds a dependency from a node object to a value::

			def build(bld):
				bld.add_manual_dependency(
					bld.path.find_resource('wscript'),
					bld.root.find_resource('/etc/fstab'))

		:param path: file path
		:type path: string or :py:class:`waflib.Node.Node`
		:param value: value to depend
		:type value: :py:class:`waflib.Node.Node`, byte object, or function returning a byte object
		s   Invalid input path %rs   Could not find the path %rN(   t
   ValueErrorR¬   R    R   R   RX   RE   RN   R,   R-   t   extendt   append(   R4   R   t   valueRP   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_manual_dependency�  s    	c         C   s?   y |  j  SWn- t k
 r: |  j j |  j ƒ |  _  |  j  SXd S(   sN   Returns the launch directory as a :py:class:`waflib.Node.Node` object (cached)N(   t   p_lnRy   RE   RY   R   (   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   launch_node¬  s
    c         C   sã   | j  s" | j } | s" t j Sn  t t | ƒ ƒ t | ƒ } y |  j } Wn t k
 rk i  } |  _ n$ Xy |  j | SWn t k
 rŽ n Xg  | D] } | | ^ q– } t j	 | ƒ | | <} t
 j d t j | ƒ | ƒ | S(   s/  
		Hashes configuration set variables::

			def build(bld):
				bld.hash_env_vars(bld.env, ['CXX', 'CC'])

		This method uses an internal cache.

		:param env: Configuration Set
		:type env: :py:class:`waflib.ConfigSet.ConfigSet`
		:param vars_lst: list of variables
		:type vars_list: list of string
		s   envhash: %s %r(   t   tablet   parentR   t   SIG_NILt   strt   idt	   cache_envRy   R³   t   h_listR   R†   t   to_hex(   R4   RT   t   vars_lstt   idxt   cachet   aRQ   R?   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   hash_env_varsµ  s"    		
c         C   s“   |  j  } | s\ xJ |  j D]< } x3 | D]+ } y | | | j <Wq& t k
 rP q& Xq& Wq Wn  y | | SWn$ t k
 rŽ t j d | ƒ ‚ n Xd S(   sn  
		Fetches a task generator by its name or its target attribute;
		the name must be unique in a build::

			def build(bld):
				tg = bld(name='foo')
				tg == bld.get_tgen_by_name('foo')

		This method use a private internal cache.

		:param name: Task generator name
		:raises: :py:class:`waflib.Errors.WafError` in case there is no task genenerator by that name
		s/   Could not find a task generator for the name %rN(   R%   R/   RS   Ry   R³   R	   RA   (   R4   RS   RÈ   t   gt   tg(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_tgen_by_nameÙ  s    	c         C   s)  t  j j ƒ  s d St t | ƒ ƒ } t j d 7_ t j t j d } d | | } d | | f } | | | | | | f }	 d | |  j | f }
 t	 j
 ƒ  t |	 ƒ t |
 ƒ d t | ƒ d t | ƒ } | d k  ræ d } n  | | | d } d	 | d
 j | ƒ } t	 j |	 | |
 f } | S(   st   
		Computes a progress bar line displayed when running ``waf -p``

		:returns: progress bar line
		:rtype: string
		R   i   i   g      Y@s    [%%%dd/%%d][%%s%%2d%%%%%%s][%s][s	   ][%s%s%s]i   i   t   =t   >(   Rm   Rn   Ro   t   lenRÁ   R   t   rot_idxt   rot_chrRk   R   t   get_term_colst   ljustt	   indicator(   R4   RÇ   t   totalt   col1t   col2t   nt   indt   pct   fst   leftt   rightt   colst   ratiot   bart   msg(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRr   ö  s     <	c         O   s   t  j | | Ž  S(   sC   
		Wraps :py:func:`waflib.TaskGen.declare_chain` for convenience
		(   R   t   declare_chain(   R4   R>   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRã     s    c         C   s+   x$ t  |  d g  ƒ D] } | |  ƒ q Wd S(   sk   Executes user-defined methods before the build starts, see :py:meth:`waflib.Build.BuildContext.add_pre_fun`t   pre_funsN(   R”   (   R4   R|   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRi     s    c         C   s+   x$ t  |  d g  ƒ D] } | |  ƒ q Wd S(   sr   Executes user-defined methods after the build is successful, see :py:meth:`waflib.Build.BuildContext.add_post_fun`t	   post_funsN(   R”   (   R4   R|   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRz      s    c         C   s8   y |  j  j | ƒ Wn t k
 r3 | g |  _  n Xd S(   sÉ   
		Binds a callback method to execute after the scripts are read and before the build starts::

			def mycallback(bld):
				print("Hello, world!")

			def build(bld):
				bld.add_pre_fun(mycallback)
		N(   Rä   R¹   Ry   (   R4   t   meth(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_pre_fun%  s    
c         C   s8   y |  j  j | ƒ Wn t k
 r3 | g |  _  n Xd S(   sì   
		Binds a callback method to execute immediately after the build is successful::

			def call_ldconfig(bld):
				bld.exec_command('/sbin/ldconfig')

			def build(bld):
				if bld.cmd == 'install':
					bld.add_pre_fun(call_ldconfig)
		N(   Rå   R¹   Ry   (   R4   Ræ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_post_fun4  s    c         C   sU   |  j  s |  j ƒ  n  | d k r0 |  j  |  j S| |  j k rJ |  j | S|  j  | S(   s�   
		Returns the build group named `x`, or the current group if `x` is None

		:param x: name or number or None
		:type x: string, int or None
		N(   R/   t	   add_groupRx   R.   R0   (   R4   RR   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt	   get_groupD  s    	c         C   sM   t  | t j ƒ s* t  | t j ƒ s* t ‚ |  | _ |  j | ƒ j | ƒ d S(   sg   Adds a task or a task generator to the build; there is no attempt to remove it if it was already added.N(   R¬   R   R<   R   t   AssertionErrorR:   Rê   R¹   (   R4   t   tgenR;   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR=   S  s    *	c         C   sZ   t  | t ƒ s |  j | } n  x4 |  j D]) } t |  j | ƒ t | ƒ k r) | Sq) Wd S(   s    
		Returns the name of the input build group

		:param g: build group object or build group index
		:type g: integer or list
		:return: name
		:rtype: string
		R   (   R¬   R,   R/   R0   RÂ   (   R4   RË   RR   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_group_nameY  s    	c         C   sW   t  | ƒ } xD t |  j ƒ D]3 \ } } x$ | D] } t  | ƒ | k r/ | Sq/ Wq Wd S(   s  
		Returns the index of the group containing the task generator given as argument::

			def build(bld):
				tg = bld(name='nada')
				0 == bld.get_group_idx(tg)

		:param tg: Task generator object
		:type tg: :py:class:`waflib.TaskGen.task_gen`
		:rtype: int
		N(   RÂ   t	   enumerateR/   Rx   (   R4   RÌ   t   seR±   t   tmpR�   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_group_idxi  s    c         C   sp   | r* | |  j  k r* t j d | ƒ ‚ n  g  } | |  j  | <|  j j | ƒ | rl t |  j ƒ d |  _ n  d S(   s•  
		Adds a new group of tasks/task generators. By default the new group becomes
		the default group for new task generators (make sure to create build groups in order).

		:param name: name for this group
		:type name: string
		:param move: set this new group as default group (True by default)
		:type move: bool
		:raises: :py:class:`waflib.Errors.WafError` if a group by the name given already exists
		s"   add_group: name %s already presenti   N(   R0   R	   RA   R/   R¹   RÐ   R.   (   R4   RS   t   moveRË   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRé   |  s    c         C   sq   t  | t ƒ rd |  j | } xN t |  j ƒ D]1 \ } } t | ƒ t | ƒ k r, | |  _ Pq, q, Wn	 | |  _ d S(   sç  
		Sets the build group at position idx as current so that newly added
		task generators are added to this one by default::

			def build(bld):
				bld(rule='touch ${TGT}', target='foo.txt')
				bld.add_group() # now the current group is 1
				bld(rule='touch ${TGT}', target='bar.txt')
				bld.set_group(0) # now the current group is 0
				bld(rule='touch ${TGT}', target='truc.txt') # build truc.txt before bar.txt

		:param idx: group name or group index
		:type idx: string or int
		N(   R¬   RÁ   R0   Rî   R/   RÂ   R.   (   R4   RÇ   RË   R±   Rð   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt	   set_group�  s    	c         C   sd   d } xW |  j  D]L } xC | D]; } y | t | j ƒ 7} Wq t k
 rW | d 7} q Xq Wq W| S(   s   
		Approximate task count: this value may be inaccurate if task generators
		are posted lazily (see :py:attr:`waflib.Build.BuildContext.post_mode`).
		The value :py:attr:`waflib.Runner.Parallel.total` is updated during the task execution.

		:rtype: int
		i    i   (   R/   RÐ   t   tasksRy   (   R4   RÖ   R;   RÌ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRÖ   §  s    c         C   s‹   g  } d } xr |  j  j d ƒ D]^ } |  j | ƒ } |  j | ƒ } | | k ra | } | g } q | | k r | j | ƒ q q W| | f S(   s“  
		This method returns a pair containing the index of the last build group to post,
		and the list of task generator objects corresponding to the target names.

		This is used internally by :py:meth:`waflib.Build.BuildContext.get_build_iterator`
		to perform partial builds::

			$ waf --targets=myprogram,myshlib

		:return: the minimum build group index, and list of task generators
		:rtype: tuple
		i    t   ,(   R(   t   splitRÍ   Rñ   R¹   (   R4   t   to_postt   min_grpRS   RÌ   R|   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_targets¸  s    c         C   s+   g  } x |  j  D] } | j | ƒ q W| S(   sI   
		Returns a list of all task generators for troubleshooting purposes.
		(   R/   R¸   (   R4   RQ   RË   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_all_task_genÑ  s    c            sª  d „  } ˆ j  d k r@ x‹ˆ j ˆ j D] } | | ƒ q) Wnfˆ j  r¤ ˆ j ˆ j k  rƒ xC ˆ j ˆ j D] } | | ƒ ql Wq¦x ˆ j D] } | j ƒ  q� Wnˆ j ƒ  ‰ ˆ j ˆ j ƒ rÛ t	 j
 d ƒ ˆ j ‰ n@ ˆ j ˆ j ƒ st	 j
 d ˆ j ƒ  ˆ j j ƒ  ƒ ˆ j ‰ n  d „  ‰  ‡  ‡ ‡ f d †  } ˆ j t k roˆ ˆ j k ro| ƒ  roˆ j ‰ qon  x4 ˆ j ˆ j D]" } ˆ  | ˆ ƒ r€| | ƒ q€q€Wd S(   s•   
		Post task generators from the group indexed by self.current_group; used internally
		by :py:meth:`waflib.Build.BuildContext.get_build_iterator`
		c         S   s,   y |  j  } Wn t k
 r  n X| ƒ  d  S(   N(   t   postRy   (   RÌ   RU   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   tgpostß  s
    t   *s6   Building from the build directory, forcing --targets=*s<   CWD %s is not under %s, forcing --targets=* (run distclean?)c         S   s8   y |  j  } Wn t k
 r  n X| j | ƒ r4 t Sd  S(   N(   R   Ry   t   is_child_ofRI   (   RÌ   t   lnt   p(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   is_postú  s    c             sZ   xS t  ˆ j ƒ D]B \ }  } |  ˆ j k r x$ | D] } ˆ  | ˆ ƒ r2 t Sq2 Wq q Wd  S(   N(   Rî   R/   R.   RI   (   R±   RË   RÌ   (   R  Rÿ   R4   (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   is_post_group  s
    N(   R(   R/   R.   t   _min_grpt	   _exact_tgRû   R½   Rþ   R]   R   t   warnRZ   RL   R   R   (   R4   Rü   RÌ   R  (    (   R  Rÿ   R4   s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt
   post_groupÚ  s2    		"			c         C   sW   g  } xJ |  j  | D]; } y | j | j ƒ Wq t k
 rN | j | ƒ q Xq W| S(   sÂ   
		Returns all task instances for the build group at position idx,
		used internally by :py:meth:`waflib.Build.BuildContext.get_build_iterator`

		:rtype: list of :py:class:`waflib.Task.Task`
		(   R/   R¸   Rô   Ry   R¹   (   R4   RÇ   Rô   RÌ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   get_tasks_group  s    c         c   s  |  j  r3 |  j  d k r3 |  j ƒ  \ |  _ |  _ n  |  j t k rr x- t |  j ƒ D] \ |  _ } |  j	 ƒ  qR Wn  x t |  j ƒ D]n \ |  _ } |  j t
 k r­ |  j	 ƒ  n  |  j |  j ƒ } t j | ƒ t j | ƒ | |  _ | r‚ | Vq‚ q‚ Wx	 g  Vq÷ Wd S(   sÞ   
		Creates a Python generator object that returns lists of tasks that may be processed in parallel.

		:return: tasks which can be executed immediately
		:rtype: generator returning lists of :py:class:`waflib.Task.Task`
		Rý   N(   R(   Rù   R  R  R   R   Rî   R/   R.   R  t   POST_AT_ONCER  R   t   set_file_constraintst   set_precedence_constraintst	   cur_tasks(   R4   t   _Rô   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR¤   "  s     	c         K   sb   | s t  ‚ |  d d d | d | | � } | j | _ d | _ | j d t ƒ s^ | j ƒ  n  | S(   sg  
		Creates a task generator to install files on the system::

			def build(bld):
				bld.install_files('${DATADIR}', self.path.find_resource('wscript'))

		:param dest: path representing the destination directory
		:type dest: :py:class:`waflib.Node.Node` or string (absolute path)
		:param files: input files
		:type files: list of strings or list of :py:class:`waflib.Node.Node`
		:param env: configuration set to expand *dest*
		:type env: :py:class:`waflib.ConfigSet.ConfigSet`
		:param relative_trick: preserve the folder hierarchy when installing whole folders
		:type relative_trick: bool
		:param cwd: parent node for searching srcfile, when srcfile is not an instance of :py:class:`waflib.Node.Node`
		:type cwd: :py:class:`waflib.Node.Node`
		:param postpone: execute the task immediately to perform the installation (False by default)
		:type postpone: bool
		t   featurest   install_taskt
   install_tot   install_fromt   install_filest   postpone(   Rë   R  t   destt   typeR   RI   Rû   (   R4   R  t   filesR5   RÌ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR  I  s    	c         K   sb   | s t  ‚ |  d d d | d | | � } | j | _ d | _ | j d t ƒ s^ | j ƒ  n  | S(   sî  
		Creates a task generator to install a file on the system with a different name::

			def build(bld):
				bld.install_as('${PREFIX}/bin', 'myapp', chmod=Utils.O755)

		:param dest: destination file
		:type dest: :py:class:`waflib.Node.Node` or string (absolute path)
		:param srcfile: input file
		:type srcfile: string or :py:class:`waflib.Node.Node`
		:param cwd: parent node for searching srcfile, when srcfile is not an instance of :py:class:`waflib.Node.Node`
		:type cwd: :py:class:`waflib.Node.Node`
		:param env: configuration set for performing substitutions in dest
		:type env: :py:class:`waflib.ConfigSet.ConfigSet`
		:param postpone: execute the task immediately to perform the installation (False by default)
		:type postpone: bool
		R  R  R  R  t
   install_asR  (   Rë   R  R  R  R   RI   Rû   (   R4   R  t   srcfileR5   RÌ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR  e  s    	c         K   sk   | s t  ‚ |  d d d | d | | � } | j | _ d | _ | | _ | j d t ƒ sg | j ƒ  n  | S(   sE  
		Creates a task generator to install a symlink::

			def build(bld):
				bld.symlink_as('${PREFIX}/lib/libfoo.so', 'libfoo.so.1.2.3')

		:param dest: absolute path of the symlink
		:type dest: :py:class:`waflib.Node.Node` or string (absolute path)
		:param src: link contents, which is a relative or absolute path which may exist or not
		:type src: string
		:param env: configuration set for performing substitutions in dest
		:type env: :py:class:`waflib.ConfigSet.ConfigSet`
		:param add: add the task created to a build group - set ``False`` only if the installation task is created after the build has started
		:type add: bool
		:param postpone: execute the task immediately to perform the installation
		:type postpone: bool
		:param relative_trick: make the symlink relative (default: ``False``)
		:type relative_trick: bool
		R  R  R  R  t
   symlink_asR  (   Rë   R  R  R  t   linkR   RI   Rû   (   R4   R  t   srcR5   RÌ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR    s    		N(2   t   __name__t
   __module__t   __doc__t   cmdR7   R   R9   t   propertyRx   R\   R@   RB   RW   R_   Rb   Ra   R`   R¢   Rl   R¨   R‚   R´   R¶   RT   R»   R½   RÊ   RÍ   Rr   Rã   Ri   Rz   Rç   Rè   Rê   R=   Rí   Rñ   RI   Ré   Ró   RÖ   Rù   Rú   R  R  R¤   R  R  R  (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR   1   sZ   	[						
	 	%									$																9		'		R  t   process_rulet   process_sourcec         C   s   |  j  |  j �  d S(   sw   Creates the installation task for the current task generator; uses :py:func:`waflib.Build.add_install_task` internally.N(   t   add_install_taskt   __dict__(   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   process_install_task�  s    c         K   sj  |  j  j s d S| d s d S| d d k rZ t j rZ | j d ƒ rS d | d <qZ d Sn  |  j d ƒ } |  _ | j d t j ƒ | _ | j d	 d
 ƒ p© | j d d
 ƒ | _	 | j d t
 ƒ | _ | d | _ | d | _ | _ | d | _ | j d ƒ p| j d |  j ƒ | _ | j d ƒ | _ | j d ƒ | _ | j ƒ  | j d t ƒ sf| j ƒ  n  | S(   s²   
	Creates the installation task for the current task generator, and executes it immediately if necessary

	:returns: An installation task
	:rtype: :py:class:`waflib.Build.inst`
	NR  R  R  t   win32_installR  t   instt   chmodR  R   R  t   relative_trickt   cwdt   relative_baset   install_usert   install_groupR  (   R:   R   R   Rš   R   t   create_taskR  t   O644R'  R  t   FalseR(  R  R  R  R  R   R*  R+  R,  t
   init_filesRI   t   run_now(   R4   R5   t   tsk(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR"  £  s,    
''
c         K   s   d | d <|  j  | �  S(   sr   
	Creates an installation task for files

	:returns: An installation task
	:rtype: :py:class:`waflib.Build.inst`
	R  R  (   R"  (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_install_filesÆ  s    
c         K   s   d | d <|  j  | �  S(   sz   
	Creates an installation task for a single file

	:returns: An installation task
	:rtype: :py:class:`waflib.Build.inst`
	R  R  (   R"  (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_install_asÑ  s    
c         K   s   d | d <|  j  | �  S(   s|   
	Creates an installation task for a symbolic link

	:returns: An installation task
	:rtype: :py:class:`waflib.Build.inst`
	R  R  (   R"  (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   add_symlink_asÜ  s    
R&  c           B   s˜   e  Z d  Z d „  Z d „  Z d „  Z d „  Z d „  Z e d „ Z	 d „  Z
 d „  Z d	 „  Z d
 „  Z d „  Z d „  Z d „  Z d „  Z d „  Z RS(   s—   Task that installs files or symlinks; it is typically executed by :py:class:`waflib.Build.InstallContext` and :py:class:`waflib.Build.UnInstallContext`c         C   s   d S(   s<   Returns an empty string to disable the standard task displayR   (    (   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   __str__é  s    c         C   s6   |  j  |  j |  j |  j j j ƒ  g } t j | ƒ S(   s(   Returns a unique identifier for the task(   t   inputst   outputsR  t	   generatorR   RL   R   RÄ   (   R4   RQ   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   uidí  s    )c         C   s‘  |  j  d k r g  } n? |  j j |  j ƒ } |  j  d k rW t | ƒ d k sW t ‚ n  |  j | ƒ |  j ƒ  } g  } |  j  d k rÚ |  j r¸ t	 j
 j |  j t	 j
 j | ƒ ƒ |  _ n  | j |  j j j j | ƒ ƒ n¦ |  j  d k r| j |  j j j j | ƒ ƒ nu xr | D]j } |  j rEt	 j
 j | | j |  j ƒ ƒ } n t	 j
 j | | j ƒ } | j |  j j j j | ƒ ƒ qW|  j | ƒ d S(   s1   
		Initializes the task input and output nodes
		R  R  i   N(   R  R9  t   to_nodesR  RÐ   Rë   t
   set_inputst   get_install_pathR(  R   R   t   relpathR  t   dirnameR¹   R:   RE   R[   R   RJ   R*  RS   t   set_outputs(   R4   R7  R  R8  t   yt   destfile(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR0  ò  s(    		*""	$#c         C   s>   t  t |  ƒ j ƒ  } | t j k r: |  j j j r: t j S| S(   s�   
		Installation tasks are always executed, so this method returns either :py:const:`waflib.Task.ASK_LATER` or :py:const:`waflib.Task.RUN_ME`.
		(	   R   R&  t   runnable_statusR   t   SKIP_MER9  R:   R   t   RUN_ME(   R4   R?   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRC    s    c         C   s   d S(   s&   
		Disables any post-run operations
		N(    (   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   post_run  s    c         C   sË   t  |  j t j ƒ r' |  j j ƒ  } n$ t j j t j |  j |  j	 ƒ ƒ } t j j
 | ƒ s{ t j j |  j	 j | ƒ } n  | rÇ t j j rÇ t j j t j j t j j | ƒ d j t j ƒ ƒ } n  | S(   s¿   
		Returns the destination path where files will be installed, pre-pending `destdir`.

		Relative paths will be interpreted relative to `PREFIX` if no `destdir` is given.

		:rtype: string
		i   (   R¬   R  R    RL   R   R   R8   R   t
   subst_varsRT   RX   R   t   PREFIXR   R&   t   destdirt
   splitdrivet   lstript   sep(   R4   RI  R  (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR=    s    $:c         C   sY   t  j r8 t | ƒ d k r8 | j d ƒ r8 d | } n  t j | | ƒ |  j | ƒ d S(   sJ  
		Copies a file from src to tgt, preserving permissions and trying to work
		around path limitations on Windows platforms. On Unix-like platforms,
		the owner/group of the target file may be set through install_user/install_group

		:param src: absolute path
		:type src: string
		:param tgt: absolute path
		:type tgt: string
		i  s   \\?\N(   R   Rš   RÐ   t
   startswitht   shutilt   copy2t	   fix_perms(   R4   R  t   tgt(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   copy_fun0  s    +c         C   sI   xB | rD t  j j | ƒ } y t  j | ƒ Wq t k
 r@ Pq Xq Wd S(   sk   
		Removes empty folders recursively when uninstalling.

		:param tgt: absolute path
		:type tgt: string
		N(   R   R   R?  t   rmdirRž   (   R4   RQ  (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   rm_empty_dirsB  s    	c         C   s  |  j  j j } | s d Sx- |  j D]" } | t k r# | j j ƒ  q# q# W|  j d k r– | t k rm |  j ps |  j	 } | |  j
 |  j d j ƒ  ƒ n{ | t k r« |  j p± |  j } |  j  j j ƒ  } xH t |  j |  j ƒ D]1 \ } } | | j ƒ  | j ƒ  | j | ƒ ƒ qÜ Wd S(   s+   
		Performs file or symlink installation
		NR  i    (   R9  R:   R   R8  t   INSTALLR¿   R^   R  t   do_linkt	   do_unlinkR  RL   t
   do_installt   do_uninstallR½   t   zipR7  RJ   (   R4   R   RR   t   funR½   RA  (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   runP  s     "c         C   sZ   |  j  ƒ  } | t j t j f k r@ t j d |  | f ƒ ‚ n  |  j ƒ  t j |  _ d S(   sf   
		Try executing the installation task right now

		:raises: :py:class:`waflib.Errors.TaskNotReady`
		s   Could not process %r: status %rN(	   RC  R   RE  RD  R	   t   TaskNotReadyR\  t   SUCCESSt   hasrun(   R4   t   status(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR1  d  s
    
c   
      K   sô  t  j j s· y" t j | ƒ } t j | ƒ } Wn t k
 rA q· X| j d | j k r· | j | j k r· |  j j	 j
 s° t j j } t j j } t j d | | | | | ƒ n  t Sn  |  j j	 j
 sý t j j } t j j } t j d | | | | | ƒ n  y0 t j | t j t j t j | ƒ j ƒ Bƒ Wn t k
 r@n Xy t j | ƒ Wn t k
 ren Xy |  j | | ƒ Wns t k
 rï}	 t j j | ƒ s±t j d | ƒ n% t j j | ƒ sÖt j d | ƒ n  t j d | |	 ƒ ‚ n Xd S(   sD  
		Copies a file from src to tgt with given file permissions. The actual copy is only performed
		if the source and target file sizes or timestamps differ. When the copy occurs,
		the file is always first removed and then copied so as to prevent stale inodes.

		:param src: file name as absolute path
		:type src: string
		:param tgt: file destination, as absolute path
		:type tgt: string
		:param lbl: file source description
		:type lbl: string
		:param chmod: installation mode
		:type chmod: int
		:raises: :py:class:`waflib.Errors.WafError` if the file cannot be written
		i   s   %s- install %s%s%s (from %s)s   %s+ install %s%s%s (from %s)s   File %r does not exists   Input %r is not a files   Could not install the file %rN(   R   R&   t   forceR   R˜   Rž   t   st_mtimet   st_sizeR9  R:   R*   R   Rs   Ru   Rt   Rg   R/  R'  R   R.  t   S_IMODEt   st_modeR~   R™   RR  R   RO   R©   t   isfileR	   RA   (
   R4   R  RQ  t   lblR5   t   st1t   st2Re   Rf   R’   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRX  p  s@    (0c         C   s´   t  j sˆ t |  d d ƒ p- t |  j d d ƒ } t |  d d ƒ pT t |  j d d ƒ } | sc | rˆ t  j | | pu d | p~ d ƒ qˆ n  t j j | ƒ s° t j	 | |  j	 ƒ n  d S(   sÎ  
		Change the ownership of the file/folder/link pointed by the given path
		This looks up for `install_user` or `install_group` attributes
		on the task or on the task generator::

			def build(bld):
				bld.install_as('${PREFIX}/wscript',
					'wscript',
					install_user='nobody', install_group='nogroup')
				bld.symlink_as('${PREFIX}/wscript_link',
					Utils.subst_vars('${PREFIX}/wscript', bld.env),
					install_user='nobody', install_group='nogroup')
		R+  R,  iÿÿÿÿN(
   R   Rš   R”   Rx   R9  t   lchownR   R   t   islinkR'  (   R4   RQ  t   userR;   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRP  ¯  s    	''%c         K   sü   t  j j | ƒ rp t  j | ƒ | k rp |  j j j sø t j j	 } t j j
 } t j d | | | | | ƒ qø nˆ y t  j | ƒ Wn t k
 r” n X|  j j j sÛ t j j	 } t j j
 } t j d | | | | | ƒ n  t  j | | ƒ |  j | ƒ d S(   s«   
		Creates a symlink from tgt to src.

		:param src: file name as absolute path
		:type src: string
		:param tgt: file destination, as absolute path
		:type tgt: string
		s   %s- symlink %s%s%s (to %s)s   %s+ symlink %s%s%s (to %s)N(   R   R   Rk  t   readlinkR9  R:   R*   R   Rs   Ru   Rt   Rg   R™   Rž   t   symlinkRP  (   R4   R  RQ  R5   Re   Rf   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRV  Å  s    	'"c         K   sæ   |  j  j j sC t j j } t j j } t j d | | | | ƒ n  y t j	 | ƒ Wn~ t
 k
 rÔ } | j t j k rÕ t |  d d ƒ s£ t |  _ t j d ƒ n  t j d k rÑ t j d | j | j ƒ qÑ qÕ n X|  j | ƒ d S(   s1   
		See :py:meth:`waflib.Build.inst.do_install`
		s   %s- remove %s%s%st   uninstall_errorsH   build: some files could not be uninstalled (retry with -vv to list them)i   s#   Could not remove %s (error code %r)N(   R9  R:   R*   R   Rs   Ru   Rt   Rg   R   R™   Rž   t   errnot   ENOENTR”   Rx   RI   Ro  R  t   verboset   filenameRT  (   R4   R  RQ  Rg  R5   Re   Rf   R’   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRY  ß  s    	#c         K   sy   yT |  j  j j sF t j j } t j j } t j d | | | | ƒ n  t j	 | ƒ Wn t
 k
 rg n X|  j | ƒ d S(   s.   
		See :py:meth:`waflib.Build.inst.do_link`
		s   %s- remove %s%s%sN(   R9  R:   R*   R   Rs   Ru   Rt   Rg   R   R™   Rž   RT  (   R4   R  RQ  R5   Re   Rf   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRW  ô  s    (   R  R  R  R6  R:  R0  RC  RF  RI   R=  RR  RT  R\  R1  RX  RP  RV  RY  RW  (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR&  ç  s    											?			t   InstallContextc           B   s   e  Z d  Z d Z d „  Z RS(   s"   installs the targets on the systemt   installc         K   s#   t  t |  ƒ j | �  t |  _ d  S(   N(   R   Rt  R   RU  R   (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR     s    (   R  R  R  R  R   (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRt    s   t   UninstallContextc           B   s   e  Z d  Z d Z d „  Z RS(   s   removes the targets installedt	   uninstallc         K   s#   t  t |  ƒ j | �  t |  _ d  S(   N(   R   Rv  R   t	   UNINSTALLR   (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR     s    (   R  R  R  R  R   (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRv  
  s   t   CleanContextc           B   s&   e  Z d  Z d Z d „  Z d „  Z RS(   s   cleans the projectt   cleanc         C   sS   |  j  ƒ  |  j s  |  j ƒ  n  |  j |  j g ƒ z |  j ƒ  Wd |  j ƒ  Xd S(   s7   
		See :py:func:`waflib.Build.BuildContext.execute`.
		N(   R`   R   RW   Rh   R   Rz  R¢   (   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRb     s    
	c            s%  t  j d ƒ t ˆ  d ƒ r= xÃ ˆ  j D] } | j ƒ  q& Wn¥ ˆ  j ˆ  j k râ g  } x8 ˆ  j j ƒ  D]' } | j	 ‡  f d †  | t
 Dƒ ƒ qe Wd t } xE ˆ  j j d d | d t ƒD]" } | | k rÑ q¹ n  | j ƒ  q¹ Wn  i  ˆ  j _ x0 t D]( } | d k rqõ n  t ˆ  | i  ƒ qõ Wd	 S(
   s  
		Remove most files from the build directory, and reset all caches.

		Custom lists of files to clean can be declared as `bld.clean_files`.
		For example, exclude `build/program/myprogram` from getting removed::

			def build(bld):
				bld.clean_files = bld.bldnode.ant_glob('**',
					excl='.lock* config.log c4che/* config.h program/myprogram',
					quiet=True, generator=True)
		s   build: clean calledt   clean_filesc         3   s!   |  ] } ˆ  j  j | ƒ Vq d  S(   N(   RE   t   find_or_declare(   t   .0RU   (   R4   (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pys	   <genexpr>8  s    s'   .lock* *conf_check_*/** config.log %s/*s   **/*t   exclRC   RE   N(   R   R†   R2   R{  t   deleteR]   RZ   R   t   valuesR¸   RM   R   RG   RI   RE   t   childrenR1   R3   (   R4   RÙ   RQ   RT   t   excluded_dirsR6   (    (   R4   s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRz  #  s$    %
%(   R  R  R  R  Rb   Rz  (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRy    s   	t   ListContextc           B   s   e  Z d  Z d Z d „  Z RS(   s   lists the targets to executeR,   c   	      C   s^  |  j  ƒ  |  j s  |  j ƒ  n  |  j |  j g ƒ |  j ƒ  t j ƒ  |  _ xJ |  j	 D]? } x6 | D]. } y | j
 } Wn t k
 r‰ qc X| ƒ  qc WqV Wy |  j d ƒ Wn t j k
 rÀ n Xt |  j ƒ } | rì t d „  | Dƒ ƒ n d } xe | D]] } |  j | } t | d d ƒ } | r@| j | ƒ } d | } n  t j d | d | ƒqù Wd S(	   sÙ   
		In addition to printing the name of each build target,
		a description column will include text for each task
		generator which has a "description" field set.

		See :py:func:`waflib.Build.BuildContext.execute`.
		R   c         s   s   |  ] } t  | ƒ Vq d  S(   N(   RÐ   (   R}  R�   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pys	   <genexpr>m  s    i    t   descriptions   : %st   GREENt   labelN(   R`   R   RW   Rh   R   Ri   R   Rj   Rk   R/   Rû   Ry   RÍ   R	   RA   t   sortedR%   t   maxR”   RÔ   R   t   pprint(	   R4   RË   RÌ   RU   R(   t	   line_justt   targetRì   t   descript(    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRb   I  s4    
	
"(   R  R  R  R  Rb   (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRƒ  E  s   t   StepContextc           B   s/   e  Z d  Z d Z d „  Z d „  Z d „  Z RS(   s7   executes tasks in a step-by-step fashion, for debuggingt   stepc         K   s)   t  t |  ƒ j | �  t j j |  _ d  S(   N(   R   R�  R   R   R&   R  (   R4   R5   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR     s    c      	   C   sÉ  |  j  s' t j d ƒ t j |  ƒ d Sg  } |  j rZ |  j d k rZ |  j j d ƒ } n  xh|  j D]]} xQ | D]I } | r’ | j | k r’ qq n  y | j	 } Wn t
 k
 r² qq X| ƒ  qq Wx |  j  j d ƒ D]ì } |  j | ƒ } xÔ | D]Ì } t | t j ƒ r| g } n	 | j } xœ | D]” } t }	 x- | j D]" }
 | |
 d t ƒr7t }	 Pq7q7Wx- | j D]" }
 | |
 d t ƒrgt }	 PqgqgW|	 r!| j ƒ  } t j d | | ƒ q!q!Wqí WqÑ Wqd Wd S(   s  
		Overrides :py:meth:`waflib.Build.BuildContext.compile` to perform a partial build
		on tasks matching the input/output pattern given (regular expression matching)::

			$ waf step --files=foo.c,bar.c,in:truc.c,out:bar.o
			$ waf step --files=in:foo.cpp.1.o # link task only

		sL   Add a pattern for the debug build, for example "waf step --files=main.c,app"NRý   Rõ   t   outputs   %s -> exit %r(   R  R   R  R   Rl   R(   Rö   R/   RS   Rû   Ry   t   get_matcherR¬   R   Rô   R/  R7  RI   R8  R\  Rg   (   R4   R(   RË   RÌ   RU   t   patt   matcherRQ   R2  t   do_execRP   R?   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRl   ƒ  sF    			c            sä   t  ‰ t  ‰ | j d ƒ r6 t ‰ | j d d ƒ } n* | j d ƒ r` t ‰ | j d d ƒ } n  |  j j | ƒ ‰  d	 ‰ ˆ  sÈ | j d ƒ sš d | } n  | j d ƒ s¶ d | } n  t j	 | ƒ ‰ n  ‡  ‡ ‡ ‡ f d †  } | S(
   sÉ   
		Converts a step pattern into a function

		:param: pat: pattern of the form in:truc.c,out:bar.o
		:returns: Python function that uses Node objects as inputs and returns matches
		:rtype: function
		s   in:R   s   out:t   ^s   ^.+?%st   $s   %s$c            sJ   | r ˆ r t  S| r# ˆ r# t  Sˆ  r3 ˆ  |  k Sˆ j |  j ƒ  ƒ Sd  S(   N(   R/  t   matchRL   (   RP   R�  (   t   anodet   innt   outt   pattern(    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR–  Ñ  s    
N(
   RI   RM  R/  RK   RE   RF   Rx   t   endswitht   reRl   (   R4   R‘  R–  (    (   R—  R˜  R™  Rš  s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR�  ¶  s$    	
(   R  R  R  R  R   Rl   R�  (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR�  {  s
   		3t
   EnvContextc           B   s!   e  Z d  Z d Z Z d „  Z RS(   sO   Subclass EnvContext to create commands that require configuration data in 'env'c         C   s7   |  j  ƒ  |  j s  |  j ƒ  n  |  j |  j g ƒ d S(   s7   
		See :py:func:`waflib.Build.BuildContext.execute`.
		N(   R`   R   RW   Rh   R   (   R4   (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyRb   à  s    
	N(   R  R  R  Rx   R[  R  Rb   (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyR�  Ý  s   
(0   R  R   Rm   Rp  Rœ  RN  R˜   R‹   t   ImportErrort   picklet   waflibR    R   R   R   R   R   R   R   R   R	   R   RH   RU  Rx  Rö   R1   RM   R  R   R–   t   platformR   t   featuret   before_methodR$  t   taskgen_methodR"  R3  R4  R5  R&  Rt  Rv  Ry  Rƒ  R�  R�  (    (    (    s/   /git_repos/PolyLV2/poly_mclk_in/waflib/Build.pyt   <module>
   sF   HF	ÿ ÿ ÿ o#ÿ 36b