î
]á[\  ã               @   s0   d  Z  d d l m Z Gd d „  d e ƒ Z d S)z•distutils.command.install_headers

Implements the Distutils 'install_headers' command, to install C/C++ header
files to the Python include directory.é    )ÚCommandc               @   sg   e  Z d  Z d Z d d g Z d g Z d d	 „  Z d
 d „  Z d d „  Z d d „  Z	 d d „  Z
 d S)Úinstall_headerszinstall C/C++ header filesúinstall-dir=Údú$directory to install header files toÚforceÚfú-force installation (overwrite existing files)c             C   s   d  |  _  d |  _ g  |  _ d  S)Nr   )Úinstall_dirr   Úoutfiles)Úself© r   ú7/usr/lib/python3.4/distutils/command/install_headers.pyÚinitialize_options   s    		z"install_headers.initialize_optionsc             C   s   |  j  d d d ƒ d  S)NZinstallr   r
   r   )zinstall_headerszinstall_dir)úforcer   )Zset_undefined_options)r   r   r   r   Úfinalize_options   s    	z install_headers.finalize_optionsc             C   sf   |  j  j } | s d  S|  j |  j ƒ x9 | D]1 } |  j | |  j ƒ \ } } |  j j | ƒ q- Wd  S)N)ÚdistributionÚheadersZmkpathr
   Z	copy_filer   Úappend)r   r   ÚheaderÚoutÚ_r   r   r   Úrun!   s    zinstall_headers.runc             C   s   |  j  j p g  S)N)r   r   )r   r   r   r   Ú
get_inputs+   s    zinstall_headers.get_inputsc             C   s   |  j  S)N)r   )r   r   r   r   Úget_outputs.   s    zinstall_headers.get_outputsN)r   r   r   )zforcer   r	   )Ú__name__Ú
__module__Ú__qualname__ZdescriptionZuser_optionsZboolean_optionsr   r   r   r   r   r   r   r   r   r   
   s     		
r   N)Ú__doc__Zdistutils.corer   r   r   r   r   r   Ú<module>   s   