o
    "g                     @   s   d dl Z d dlmZ d dlmZmZ g dZdd ZG dd deZG d	d
 d
eZ	G dd de	Z
G dd de	ZG dd deZG dd deZG dd deZedkrrd dlmZ ed d dlmZ eedd  dS dS )    Nsimple_version_match)	FCompilerdummy_fortran_file)IntelFCompilerIntelVisualFCompilerIntelItaniumFCompilerIntelItaniumVisualFCompilerIntelEM64VisualFCompilerIntelEM64TFCompilerc                 C   s   t d| f dS )Nz"Intel.*?Fortran.*?(?:%s).*?Versionstartr   )type r   a/var/www/html/ecg_monitoring/venv/lib/python3.10/site-packages/numpy/distutils/fcompiler/intel.pyintel_version_match   s   r   c                   @   s   e Zd Zdd Zdd ZdS )BaseIntelFCompilerc                 C   s*   t  }dddd|d d|d g| jd< d S )	N<F77>-FIz-Vz-c.fz-o.oversion_cmdr   executablesselffr   r   r   update_executables   s   z%BaseIntelFCompiler.update_executablesc                 C   s   d|vsJ d| S )N,z-Wl,-rpath=%sr   r   dirr   r   r   runtime_library_dir_option   s   z-BaseIntelFCompiler.runtime_library_dir_optionN)__name__
__module____qualname__r   r!   r   r   r   r   r      s    r   c                   @   s   e Zd ZdZdZdZedZddgZdg ddgdd	gd
dgddgdgdZ	dgZ
dZdZdd Zdd Zdd Zdd Zdd ZdS )r   intel)ifortz&Intel Fortran Compiler for 32-bit apps32-bit|IA-32r&   ifcN)Nz-72-w90-w95r   <F90>-sharedar-crranlib)r   compiler_f77compiler_f90compiler_fix	linker_soarchiverr/   -fPICz-module z-Ic                 C      dgS )Nz-FRr   r   r   r   r   get_flags_free5      zIntelFCompiler.get_flags_freec                 C   r6   )Nr5   r   r7   r   r   r   	get_flags8   r9   zIntelFCompiler.get_flagsc                 C   s2   |   }|r|dk rdnd}dddddd	|gS )
N15openmpqopenmpz	-fp-modelstrictz-O1z-assumeminus0z-{})get_versionformat)r   vmpoptr   r   r   get_flags_opt;   s
   zIntelFCompiler.get_flags_optc                 C      g S Nr   r7   r   r   r   get_flags_archA      zIntelFCompiler.get_flags_archc                 C   sv   t | }|  }|r|dkr|d tjdkr9z|d}|d W n ty0   d}Y nw ddg|||< |S )Nz8.0z-nofor_maindarwinr,   r   z-dynamiclibz-Wl,-undefined,dynamic_lookup)	r   get_flags_linker_sor@   appendsysplatformindexremove
ValueError)r   optrB   idxr   r   r   rJ   D   s   



z"IntelFCompiler.get_flags_linker_so)r"   r#   r$   compiler_typecompiler_aliasesdescriptionr   version_matchpossible_executablesr   	pic_flagsmodule_dir_switchmodule_include_switchr8   r:   rD   rG   rJ   r   r   r   r   r      s,    
r   c                   @   sP   e Zd ZdZdZdZedZg dZdg dddgdgd	d
gddgdgdZ	dS )r   inteler   z'Intel Fortran Compiler for Itanium appszItanium|IA-64r&   efortefcNNr   r)   r*   r   r+   r,   r-   r.   r/   r   r0   r2   r1   r3   r4   r/   
r"   r#   r$   rS   rT   rU   r   rV   rW   r   r   r   r   r   r   T       
r   c                   @   sP   e Zd ZdZdZdZedZg dZdddgddgdgdd	gd
dgdgdZ	dS )r   intelemr   z&Intel Fortran Compiler for 64-bit appsz)EM64T-based|Intel\(R\) 64|64|IA-64|64-bitr\   Nr   r+   r,   r-   r.   r/   r`   ra   r   r   r   r   r   h   rb   r   c                   @   s   e Zd ZdZdZedZdd ZdZddgZ	d	d	gd	gd	gd	ged
dgd	dZ
dZdZdZdZdZdd Zdd Zdd Zdd Zdd Zdd Zd	S )r   intelvz-Intel Visual Fortran Compiler for 32-bit appsr'   c                 C   s(   t  }ddd|d d|d g| jd< d S )Nr   z/FIz/cr   z/or   r   r   r   r   r   r   r      s   z'IntelVisualFCompiler.update_executableszlib.exer&   iflN/verbose/OUT:r`   z/c z/Foz/module:z/Ic                 C   s   g d}|S )N)z/nologoz/MDz/nbsz/names:lowercasez/assume:underscorez/fppr   )r   rQ   r   r   r   r:      s   zIntelVisualFCompiler.get_flagsc                 C   rE   rF   r   r7   r   r   r   r8      rH   z#IntelVisualFCompiler.get_flags_freec                 C      ddgS )Nz/4Ybz/d2r   r7   r   r   r   get_flags_debug      z$IntelVisualFCompiler.get_flags_debugc                 C   rh   )Nz/O1z/assume:minus0r   r7   r   r   r   rD      rj   z"IntelVisualFCompiler.get_flags_optc                 C   rh   )Nz
/arch:IA32z/QaxSSE3r   r7   r   r   r   rG      rj   z#IntelVisualFCompiler.get_flags_archc                 C   s   t rF   )NotImplementedErrorr   r   r   r   r!      rH   z/IntelVisualFCompiler.runtime_library_dir_option)r"   r#   r$   rS   rU   r   rV   r   ar_exerW   r   compile_switchobject_switchlibrary_switchrY   rZ   r:   r8   ri   rD   rG   r!   r   r   r   r   r      s4    
r   c                   @   sP   e Zd ZdZdZedZdgZej	Z	dg dg ddgdd	ge	d
dgddZ
dS )r	   intelevz.Intel Visual Fortran Compiler for Itanium appsItaniumeflNr_   )Nr   z-4L72z-wr+   r,   rf   rg   r`   )r"   r#   r$   rS   rU   r   rV   rW   r   rl   r   r   r   r   r   r	      s    
r	   c                   @   s&   e Zd ZdZdZeddZdd ZdS )r
   intelvemz-Intel Visual Fortran Compiler for 64-bit appszIntel\(R\).*?64,r   c                 C   rE   rF   r   r7   r   r   r   rG      rH   z'IntelEM64VisualFCompiler.get_flags_archN)r"   r#   r$   rS   rU   r   rV   rG   r   r   r   r   r
      s
    
r
   __main__)log   )customized_fcompilerr%   )compiler)rL   numpy.distutils.ccompilerr   numpy.distutils.fcompilerr   r   	compilersr   r   r   r   r   r   r	   r
   r"   	distutilsru   set_verbositynumpy.distutilsrw   printr@   r   r   r   r   <module>   s$   62

