Current File : //usr/lib/python3/dist-packages/setuptools/_distutils/command/__pycache__/bdist.cpython-312.pyc
�


_�d ��r�dZddlZddlZddlmZddlmZmZddlm	Z	d�Z
Gd�d	e�ZGd
�de�Z
y)zidistutils.command.bdist

Implements the Distutils 'bdist' command (create a built [binary]
distribution).�N�)�Command)�DistutilsPlatformError�DistutilsOptionError)�get_platformc���ddlm}g}tjD]-}|j	d|zdtj|df��/||�}|jd�y)zAPrint list of available formats (arguments to "--format" option).r)�FancyGetopt�formats=N�z'List of available distribution formats:)�fancy_getoptr	�bdist�format_commands�append�
print_help)r	�formats�format�pretty_printers    �E/usr/lib/python3/dist-packages/setuptools/_distutils/command/bdist.py�show_formatsrsc��*��G��'�'�V�����
�V�+�T�5�3H�3H��3P�QR�3S�T�U�V� ��)�N����G�H�c��eZdZd�Zy)�
ListCompatc�<�tjdtd��y)Nz4format_commands is now a dict. append is deprecated.r)�
stacklevel)�warnings�warn�DeprecationWarning)�self�items  rrzListCompat.appends���
�
�F���	
rN)�__name__�
__module__�__qualname__r�rrrrs��
rrc
��eZdZdZdddde�zfdddd	d
gZdgZdd
defgZdZ	ddd�Z
edddddddd��ZeZ
d�Zd�Zd�Zy
)r
z$create a built (binary) distribution)zbdist-base=�bz4temporary directory for creating built distributionsz
plat-name=�pz;platform name to embed in generated filenames (default: %s))r
Nz/formats for distribution (comma-separated list))z	dist-dir=�dz=directory to put final built distributions in [default: dist])�
skip-buildNz2skip rebuilding everything (for testing/debugging))zowner=�uz@Owner name used when creating a tar file [default: current user])zgroup=�gzAGroup name used when creating a tar file [default: current group]r(zhelp-formatsNz$lists available distribution formats)�	bdist_rpm�gztar�zip)�posix�nt)r+zRPM distribution)�
bdist_dumbzgzip'ed tar file)r0zbzip2'ed tar file)r0zxz'ed tar file)r0zcompressed tar file)r0ztar file)r0zZIP file)�rpmr,�bztar�xztar�ztar�tarr-c�f�d|_d|_d|_d|_d|_d|_d|_y)Nr)�
bdist_base�	plat_namer�dist_dir�
skip_build�group�owner)rs r�initialize_optionszbdist.initialize_options^s3�������������
������
���
rc�B�|j�<|jrt�|_n |jd�j|_|j�M|jd�j
}tjj|d|jz�|_|jd�|j�$	|jtjg|_
|j�d|_yy#t$rtdtjz��wxYw)N�buildzbdist.rz;don't know how to create built distributions on platform %s�dist)r8r:r�get_finalized_commandr7�
build_base�os�path�join�ensure_string_listr�default_format�name�KeyErrorrr9)rrBs  r�finalize_optionszbdist.finalize_optionsgs����>�>�!����!-����!%�!;�!;�G�!D�!N�!N���
�?�?�"��3�3�G�<�G�G�J� �g�g�l�l�:�x�$�.�.�7P�Q�D�O����	�*��<�<��
� $� 3� 3�B�G�G� <�=����=�=� �"�D�M�!��
�
�,�%�')�w�w�/���
�s�#C8�8&Dc���g}|jD]$}	|j|j|d��&tt
|j��D]�}||}|j|�}||jvr|j||_	|dk(r"|j|_
|j|_|||dzdvrd|_|j|���y#t$rt	d|z��wxYw)Nrzinvalid format '%s'r0r)rrrrIr�range�len�reinitialize_command�no_format_optionrr<r;�	keep_temp�run_command)r�commandsr�i�cmd_name�sub_cmds      r�runz	bdist.run�s�����l�l�	K�F�
K����� 4� 4�V� <�Q� ?�@�	K��s�4�<�<�(�)�	'�A���{�H��/�/��9�G��t�4�4�4�!%���a�����<�'� $�
�
��
� $�
�
��
��8�A��E�G�,�,�$%��!����X�&�	'��	�
K�*�+@�6�+I�J�J�
K�s�!C�C3)r r!r"�descriptionr�user_options�boolean_optionsr�help_optionsrOrGrr�format_commandr=rJrVr#rrr
r
#s���8�K�	U���
�*�n�
-�	
�	N�	
�
	S�	
�
	
�)�L�6$�n�O�
��E�|�T��L�
&�� '�e�4�N�!�4�7�8�5�9�-�-�	
�
�O�%�N��#�8'rr
)�__doc__rCr�corer�errorsrr�utilrr�dictrr
r#rr�<module>ras;���

���A��I�
��
�y'�G�y'r