Hacked By AnonymousFox

Current Path : /opt/cloudlinux/venv/lib64/python3.11/site-packages/numpy/distutils/command/__pycache__/
Upload File :
Current File : //opt/cloudlinux/venv/lib64/python3.11/site-packages/numpy/distutils/command/__pycache__/config.cpython-311.pyc

�

�܋f�P���ddlZddlZddlZddlZddlZddlZddlmZddlm	Z	ddl
mZddlm
Z
ddlmZmZddl
Z
ddlmZddlmZdd	lmZmZmZmZmZmZmZd
e	d<de	d
<Gd�de��ZGd�d��ZdS)�N)�config)�LANG_EXT)�log)�	copy_file)�CompileError�	LinkError)�filepath_from_subprocess_output)�generate_manifest)�check_gcc_function_attribute�,check_gcc_function_attribute_with_intrinsics�check_gcc_variable_attribute�check_gcc_version_at_least�check_inline�check_restrict�check_compiler_gccz.f�f77z.f90�f90c���eZdZexjdgz
c_d�Zd�Zd�Zd�Zd�Z	dd	�Z
	dd
�Z	dd�Z		dd�Z
dd
�Z			dd�Z			dd�Zd�Zd�Zd�Zd�Zd�Zd�Zdd�Z			d d�ZdS)!r)z
fcompiler=Nz!specify the Fortran compiler typec�<�d|_tj|��dS�N)�	fcompiler�
old_config�initialize_options��selfs �q/builddir/build/BUILD/cloudlinux-venv-1.0.6/venv/lib64/python3.11/site-packages/numpy/distutils/command/config.pyrzconfig.initialize_options$s ������%�d�+�+�+�+�+�c���tj|��ddlm}m}t
jdk�r|jjdvr�|jj	s�	|j�
��n{#t$rn}tj
d��||jjjfz}t!tj
d����t"j�|��|�d}~wwxYwddlm}|���dkr4|jj|jjfD]}d	|vr|�d	���t3|j|��s�||j|jd
|j���|_|j�o|j�|j��|j���r9|j�|��|j� ��dSdSdSdS)Nr)�	FCompiler�
new_fcompiler�win32)�msvc�intelw�intelemwa>                        Could not initialize compiler instance: do you have Visual Studio
                        installed?  If you are trying to build with MinGW, please use "python setup.py
                        build -c mingw32" instead.  If you have Visual Studio installed, check it is
                        correctly installed, and the right version (VS 2015 as of this writing).

                        Original exception was: %s, and the Compiler class was %s
                        ============================================================================zd                        ============================================================================)�
msvc9compiler�
z	/MANIFEST�)�compiler�dry_run�force�
c_compiler)!r�_check_compiler�numpy.distutils.fcompilerrr �sys�platformr(�
compiler_type�initialized�
initialize�IOError�textwrap�dedent�	__class__�__name__�print�	distutils�errors�DistutilsPlatformErrorr%�get_build_version�ldflags_shared�ldflags_shared_debug�append�
isinstancerr)�	customize�distribution�get_version�
customize_cmd�show_customization)rrr �e�msgr%�ldflagss       rr,zconfig._check_compiler(sD���"�4�(�(�(�F�F�F�F�F�F�F�F��<�7�"�"��
�(C�(F�)G�)G��=�,�
N�N��M�,�,�.�.�.�.���N�N�N�"�/�+h�i�i��d�m�5�>�?�@�C��(�/�+h�i�i�j�j�j�#�*�A�A�#�F�F�A�M�����N����"
0�/�/�/�/�/��.�.�0�0�B�6�6� $�
� <� $�
� B� D�4�4�G�"�'�1�1����{�3�3�3���$�.�)�4�4�	8�*�]�D�N�37�<�q�6:�m�E�E�E�D�N��~�)���(�(��):�;�;�;��>�-�-�/�/�8��N�0�0��6�6�6��N�5�5�7�7�7�7�7�	8�	8�*�)�8�8s�	A#�#
C�-A)C�Cc���ddlm}ddlm}|j}|dvr|j|_|j�||�d����	||f|z�}n#||f$r}||_||�d}~wwxYw||_|S)Nr)r)�DistutilsExecError�rrz compiler is not set)�distutils.ccompilerr�distutils.errorsrJr(r)	r�mth�lang�argsrrJ�
save_compiler�retrFs	         r�_wrap_methodzconfig._wrap_methodXs���4�4�4�4�4�4�7�7�7�7�7�7��
�
��>�!�!� �N�D�M��=� ��,�4�4�4�A�B�B�B�	&��#�����&�C�C��"�L�1�	&�	&�	&�)�D�M��A�%�����	&����&��
��
s�	A�A�
A�Ac��|�tj|||||f��\}}|j�|dz��||fS)Nz.d)rSr�_compile�
temp_filesr?)r�body�headers�include_dirsrO�src�objs       rrUzconfig._compilehsU���$�$�Z�%8�$�&*�G�\�4�%H�J�J���S�	
����s�T�z�*�*�*��C�x�rc
��|jjdk�r�|pgdd�}|pgdd�}|dvr�d}|jr�|jjpgD]p}|�d��rD	tjdd|g��}t|��}n#tt
j	f$rYnwxYw|�
|���q|jjpgD]}||vr|�
|���|D�]#}|�d��r�d}	|pgD]H}
tj
�|
d|z��}tj
�|��rd	}	n�I|	r�kd}	|D]�}
tj
�|
d
|z��}tj
�|��rQtj
�|
d|z��}t!||��|j�
|��d	}	n��|	r��	t%jd|�d|������%n|jjd
krt)|��|�t,j|||||||f��S)Nr"rK�cz/usr/lib�cygpathz-wFz%s.libTzlib%s.azcould not find library z in directories �mingw32)r(r0r�library_dirs�
startswith�
subprocess�check_outputr	�OSError�CalledProcessErrorr?�	libraries�os�path�join�isfilerrVr�warnr
rSr�_link)
rrWrXrYrfr`rO�d�libname�
fileexists�libdir�libfile�libfile2s
             rrlzconfig._linkps����=�&��.�.�"��b�!�!�!�,�I�(�.�B����2�L��~�%�%����>�6�!�^�8�>�B�/�/���<�<�
�3�3�G�G�$.�$;�Y�=A�1�=F�%G�%G��
%D�A�$F�$F����%,�Z�-J�#K�%�%�%� $��%����%�+�+�A�.�.�.�.�#'�>�#;�#A�r�6�6��"�)�3�3�%�,�,�W�5�5�5��$�
4�
4���%�%�f�-�-�7�x�"�
�*�0�b���F� �g�l�l�6�8�w�3G�H�H�G��w�~�~�g�.�.��%)�
�����'�x�"�
�*�	�	�F� �g�l�l�6�9��3H�I�I�G��w�~�~�g�.�.��$&�7�<�<���G�8L�#M�#M��!�'�8�4�4�4���.�.�x�8�8�8�%)�
�����'�x����#�G�G�\�\�3�4�4�4�4�-
4�0�]�
(�I�
5�
5��d�#�#�#�� � ��!1�4�"&���"+�\�4�"A�B�B�	Bs�B�B�BNr]c�Z�|���|�d|g|��S)Nz2/* we need a dummy line to make distutils happy */)r,�try_compile)r�headerrYr`rOs     r�check_headerzconfig.check_header�s6�����������D���,�(�(�	(rc��|���tjd��||fz}|�|||��S)Nz�
            int main(void)
            {
            #ifndef %s
                (void) %s;
            #endif
                ;
                return 0;
            }�r,r4r5rt�r�symbolrXrYrWs     r�
check_declzconfig.check_decl�sS���������� ����V�$�%������g�|�<�<�<rc��|���tjd��|fz}|�|||��S)Nz�
            int main(void)
            {
            #if %s
            #else
            #error false or undefined macro
            #endif
                ;
                return 0;
            }rxrys     r�check_macro_truezconfig.check_macro_true�sP����������	 �	�	��I�	������g�|�<�<�<rc�<�|���tjd��d|iz}d}		|�|d|iz||d��d}n#tjj$rd}YnwxYw|���n#|���wxYw|S)zYCheck type availability. Return True if the type can be compiled,
        False otherwisez�
            int main(void) {
              if ((%(name)s *) 0)
                return 0;
              if (sizeof (%(name)s))
                return 0;
            }
            �nameF�typer]T)r,r4r5rUr9r:r�_clean)r�	type_namerXrYr`rW�sts       r�
check_typezconfig.check_type�s���	
�������� ����I�&�'����	�
��
�
�d�f�i�%8�8���s�4�4�4������#�0�
�
�
�����
����
�K�K�M�M�M�M��D�K�K�M�M�M�M�����	s)�A�B�A+�(B�*A+�+B�Bc��|���tjd��}|�|d|iz||d��|���|r_tjd��}|D]H}	|�|||d�z||d��|���|cS#t
$rY�EwxYwtjd��}d}d}			|�|||	d�z||d��|���n#t
$r|	d	z}d
|	zd	z}	YnwxYw�R|	}
||
kr\|
|z
d
z|z}		|�|||	d�z||d��|���|	}
n#t
$r|	d	z}YnwxYw||
k�\|S)zCheck size of a given type.a,
            typedef %(type)s npy_check_sizeof_type;
            int main (void)
            {
                static int test_array [1 - 2 * !(((long) (sizeof (npy_check_sizeof_type))) >= 0)];
                test_array [0] = 0

                ;
                return 0;
            }
            r�r]aW
                typedef %(type)s npy_check_sizeof_type;
                int main (void)
                {
                    static int test_array [1 - 2 * !(((long) (sizeof (npy_check_sizeof_type))) == %(size)s)];
                    test_array [0] = 0

                    ;
                    return 0;
                }
                )r��sizea3
            typedef %(type)s npy_check_sizeof_type;
            int main (void)
            {
                static int test_array [1 - 2 * !(((long) (sizeof (npy_check_sizeof_type))) <= %(size)s)];
                test_array [0] = 0

                ;
                return 0;
            }
            rTr'�)r,r4r5rUr�r)rr�rXrYr`�expectedrWr��low�mid�highs           r�check_type_sizezconfig.check_type_size�s@����������
 �
�
��	
�
�
�d�f�i�0�0���s�	,�	,�	,����
�
�
��	��?�
$�
�
�D�!�
�
����M�M�$�)�T�)J�)J�"J�#�\�3�8�8�8��K�K�M�M�M��K�K�K��#�����D�������
 �
�
������		"�
"��
�
�d�i��%E�%E�E���s�4�4�4����
�
�
����
"�
"�
"��A�g���#�g��k����
"����
		"����T�k�k��#�:�!�#�c�)�C�
��
�
�d�i��%E�%E�E���s�4�4�4����
�
�
������
�
�
��A�g����
�����T�k�k��
s6�53B+�+
B8�7B8�2D�D"�!D"�:4E/�/F�FFc	��|���g}	|rFt|��tkr|	�|��n|	�d|z��|	�d��|	�d|z��|	�d��|	�d��|r!|�d}|	�d|�d|�d	���n|	�d
|z��|	�d��|	�d��d
�|	��d
z}	|�|	||||��S)N�int %s (void);�#ifdef _MSC_VER�#pragma function(%s)�#endif�int main (void) {��  �(�);�  %s;�  return 0;�}�
)r,r��strr?ri�try_link)
r�funcrXrYrfr`�decl�call�	call_argsrWs
          r�
check_funczconfig.check_func;sY��	
���������	5��D�z�z�S� � ����D�!�!�!�!����,�t�3�4�4�4�
	
���%�&�&�&����*�T�1�2�2�2����H�������'�(�(�(��	(�� ��	��K�K�K�t�t�t�Y�Y�Y�7�8�8�8�8��K�K��$��'�'�'����M�"�"�"����C�����y�y�����%���}�}�T�7�L�&��6�6�	6rc	��|���g}	|r4|���D]\}
}|r|	�d|
z��� |	�d��|D]}|	�d|z���|	�d��|	�d��|r`|D]\}
|
|vr>||
r6|r|
|vr||
sd}
n||
}
|	�d|
�d|
�d	����D|	�d
|
z���]n|D]}
|	�d
|
z���|	�d��|	�d��d
�|	��d
z}	|�|	||||��S)a0Check a list of functions at once.

        This is useful to speed up things, since all the functions in the funcs
        list will be put in one compilation unit.

        Arguments
        ---------
        funcs : seq
            list of functions to test
        include_dirs : seq
            list of header paths
        libraries : seq
            list of libraries to link the code snippet to
        library_dirs : seq
            list of library paths
        decl : dict
            for every (key, value), the declaration in the value will be
            used for function in key. If a function is not in the
            dictionary, no declaration will be used.
        call : dict
            for every item (f, value), if the value is True, a call will be
            done to the function f.
        r�r�r�r�r�r�r�r�r�r�r�r�r�)r,�itemsr?rir�)r�funcsrXrYrfr`r�r�r�rW�f�vr�rPs              r�check_funcs_oncezconfig.check_funcs_once]s���6	
���������	6��
�
���
6�
6���1��6��K�K� 0�1� 4�5�5�5��	
���%�&�&�&��	7�	7�D��K�K�.��5�6�6�6�6����H�������'�(�(�(��	)��
-�
-����9�9��a��9�%�,�!�y�.�.�Y�q�\�.�!���(��|���K�K�K�q�q�q�$�$�$� 7�8�8�8�8��K�K��!��,�,�,�,�
-��
)�
)�����G�a�K�(�(�(�(����M�"�"�"����C�����y�y�����%���}�}�T�7�L�&��6�6�	6rc� �t|��S)zUReturn the inline keyword recognized by the compiler, empty string
        otherwise.)rrs rrzconfig.check_inline�s���D�!�!�!rc� �t|��S)zWReturn the restrict keyword recognized by the compiler, empty string
        otherwise.)rrs rrzconfig.check_restrict�s���d�#�#�#rc� �t|��S)z$Return True if the C compiler is gcc)rrs rrzconfig.check_compiler_gcc�s��!�$�'�'�'rc�$�t|||��Sr)r)r�	attributers   rrz#config.check_gcc_function_attribute�s��+�D�)�T�B�B�Brc�(�t|||||��Sr)r)rr�r�code�includes     rrz3config.check_gcc_function_attribute_with_intrinsics�s"��;�D�)�<@�$��Q�Q�	Qrc�"�t||��Sr)r
)rr�s  rr
z#config.check_gcc_variable_attribute�s��+�D�)�<�<�<rrc�&�t||||��S)zYReturn True if the GCC version is greater than or equal to the
        specified version.)r)r�major�minor�
patchlevels    rrz!config.check_gcc_version_at_least�s��*�$��u�j�I�I�Irc���tjdtd���|���d\}}		t	��}
	|�||||||��\}}}
|
���n*#t$r|
j}	|
����wxYwtj
�d|
��}
	tj
|
gd���}	t|	��}	n4#tj$r}|j}d}	Yd}~nd}~wt"$rd	}d}	YnwxYwt%td
��rltj|��}tj|��rCtj|��}t-jd|fz��|t0jkrt4�n|}t-jd��n+#t8t:f$rt-jd
��YnwxYw|���||	fS)z�Try to compile, link to an executable, and run a program
        built from 'body' and 'headers'. Returns the exit status code
        of the program and its output.
        z�
+++++++++++++++++++++++++++++++++++++++++++++++++
Usage of get_output is deprecated: please do not 
use it anymore, and avoid configuration checks 
involving running executable on the target machine.
+++++++++++++++++++++++++++++++++++++++++++++++++
r�)�
stacklevel)�r��.)�cwdr�N��WEXITSTATUSz subprocess exited with signal %dzsuccess!zfailure.)�warningsrk�DeprecationWarningr,�
GrabStdoutrl�restore�	Exception�datargrhrirbrcr	re�
returncoderd�hasattrr��WIFSIGNALED�WTERMSIGr�error�signal�SIGINT�KeyboardInterrupt�inforrr�)rrWrXrYrfr`rO�use_tee�exitcode�output�grabberrZr[�exe�exc�
exitstatus�sigs                 r�
get_outputzconfig.get_output�sD��	�
�L�
)�Q�	8�	8�	8�	8�	
������"���&�)	!� �l�l�G�
� $�
�
�4��,�+4�l�D�!J�!J�
��S�#����!�!�!�!���
�
�
� ������!�!�!��
�����'�,�,�s�C�(�(�C�
A�$�0�#��C�@�@�@��9��@�@�����0�
�
�
� �^�
�������������
�
�
�!�
�����	
�����r�=�)�)�	
&��>�*�5�5���>�*�-�-�0��+�j�1�1�C��I�@�C�6�I�J�J�J��f�m�+�+�/�/��%���H�Z� � � � ���i�(�	!�	!�	!��H�Z� � � � � �	!�������
�
�
����s`�F7�2A9�8F7�9'B � #F7�C+�F7�+D�:	D�F7�D�F7�D�BF7�7%G�G)NNr])NN)NNN)NNNN)NNNNFFN)rr)NNNNr]N)r7�
__module__�__qualname__r�user_optionsrr,rSrUrlrvr{r}r�r�r�r�rrrrrr
rr��rrrrs����������A� 
�
���,�,�,�.8�.8�.8�`��� ���4B�4B�4B�l(�(�(�(�/3�
=�
=�
=�
=� 59�=�=�=�=� @D������:Q�Q�Q�Q�h/3�04�59� 6� 6� 6� 6�F/3�04�59�;6�;6�;6�;6�z"�"�"�
$�$�$�
(�(�(�C�C�C�Q�Q�Q�
=�=�=�J�J�J�J�
;?�04�%)�; �; �; �; �; �; rrc�&�eZdZd�Zd�Zd�Zd�ZdS)r�c�N�tj|_d|_|t_dS)Nr�)r.�stdout�
sys_stdoutr�rs r�__init__zGrabStdout.__init__�s���*�����	���
�
�
rc�Z�|j�|��|xj|z
c_dSr)r��writer�)rr�s  rr�zGrabStdout.write�s,������d�#�#�#��	�	�T��	�	�	�	rc�8�|j���dSr)r��flushrs rr�zGrabStdout.flushs����������rc�(�|jt_dSr)r�r.r�rs rr�zGrabStdout.restores���_��
�
�
rN)r7r�r�r�r�r�r�r�rrr�r��sP���������
��� � � �%�%�%�%�%rr�)rgr�rbr.r4r��distutils.command.configrrrr9r�distutils.file_utilrrLrr�numpy.distutils.exec_commandr	� numpy.distutils.mingw32ccompilerr
� numpy.distutils.command.autodistrrr
rrrrr�r�rr�<module>r�s���

�	�	�	�
�
�
�
�����
�
�
�
���������9�9�9�9�9�9�-�-�-�-�-�-�������)�)�)�)�)�)�7�7�7�7�7�7�7�7�����H�H�H�H�H�H�>�>�>�>�>�>�B�B�B�B�B�B�B�B�B�B�B�B�B�B�B�B�B�B���������T �T �T �T �T �Z�T �T �T �l%�%�%�%�%�%�%�%�%�%r

Hacked By AnonymousFox1.0, Coded By AnonymousFox