B
    ›³ëb8
  ã               @   s`   d Z ddlZddlZddlZddlmZ ddlmZ ddlZej	j
Zdd„ Zdd	„ Zd
d„ ZdS )zêSCons.Tool.aixlink

Tool-specific initialization for the IBM Visual Age linker.

There normally shouldn't be any need to import this module directly.
It will usually be imported through the generic SCons.Tool.Tool()
selection method.
é    Né   )Úaixcc)Úlinkc             C   s4   t  | ¡r0|jd|| d}|r0dtj |d¡ S dS )Nz	$BUILDDIR)ÚtargetÚsourcez
-qtempinc=ZtempincÚ )Ú	cplusplusZiscplusplusZsubstÚosÚpathÚjoin)r   r   ÚenvZfor_signatureZ	build_dir© r   ú1lib/python3.7/site-packages/SCons/Tool/aixlink.pyÚsmart_linkflags+   s
    
r   c             C   s>   t  | ¡ t| d< tj d¡| d< tj d¡| d< d| d< dS )	z^
    Add Builders and construction variables for Visual Age linker to
    an Environment.
    ZSMARTLINKFLAGSz$SMARTLINKFLAGSZ	LINKFLAGSz)$LINKFLAGS -qmkshrobj -qsuppress=1501-218ZSHLINKFLAGSz.aZSHLIBSUFFIXN)r   Úgenerater   ÚSConsZUtilZCLVar)r   r   r   r   r   3   s
    
r   c             C   sV   dgdgdœ}g }x4|  ¡ D ](\}}|| kr:tj || ¡S | |¡ qW tj || ¡S )Nzaixc++r   )ZCXXZCC)Úitemsr   ÚToolZFindToolÚextend)r   ZlinkersZalltoolsZlangvarZ	linktoolsr   r   r   Úexists@   s    r   )Ú__doc__r	   Úos.pathZ
SCons.Utilr   r   r   r   ZSCons.Tool.cxxr   Zcxxr   r   r   r   r   r   r   r   Ú<module>   s   