�
,�Re� � �~ � d dl mZmZ d dlZd dlmZ d dlmZ d dlmZ ddl m
Z
d dlZ G d� d ej e� � Z
dS )
� )�log�dir_utilN)�Command)�
namespaces)�unpack_archive� )�ensure_directoryc �: � e Zd ZdZdZdgZd� Zd� Zd� Zd� Z d� Z
dS ) �install_egg_infoz.Install an .egg-info directory for the package)zinstall-dir=�dzdirectory to install toc � � d | _ d S �N)�install_dir��selfs ��/builddir/build/BUILDROOT/alt-python311-setuptools-65.6.3-2.el8.x86_64/opt/alt/python311/lib/python3.11/site-packages/setuptools/command/install_egg_info.py�initialize_optionsz#install_egg_info.initialize_options s � ������ c �B � | � dd� � | � d� � }t j d d |j |j � � � � � dz }|j | _ t j �
| j |� � | _ g | _
d S )N�install_lib)r r �egg_infoz .egg-info)�set_undefined_options�get_finalized_command�
pkg_resources�Distribution�egg_name�egg_versionr �source�os�path�joinr �target�outputs)r �ei_cmd�basenames r �finalize_optionsz!install_egg_info.finalize_options s� � ��"�"�=�#A� C� C� C��+�+�J�7�7�� �-��$����);�
�
�
�(�*�*�{�#�� �o����g�l�l�4�#3�X�>�>�������r c �^ � | � d� � t j � | j � � rEt j � | j � � s!t
j | j | j �� � nSt j � | j � � r/| �
t j | j fd| j z � � | j st | j � � | �
| j
dd| j �d| j ��� � | � � � d S )Nr )�dry_runz Removing � zCopying z to )�run_commandr r �isdirr" �islinkr �remove_treer( �exists�execute�unlinkr �copytreer �install_namespacesr s r �runzinstall_egg_info.run" s � �����$�$�$�
�7�=�=���%�%� O�b�g�n�n�T�[�.I�.I� O�� ���d�l�C�C�C�C�C�
�W�^�^�D�K�
(�
(� O��L�L���T�[�N�K�$�+�4M�N�N�N��|� *��T�[�)�)�)�����M�2�2�T�[�[�[�$�+�+�N�
�
�
�
���!�!�!�!�!r c � � | j S r )r# r s r �get_outputszinstall_egg_info.get_outputs/ s
� ��|�r c �H � � � fd�}t � j � j |� � d S )Nc � �� dD ]!}| � |� � sd|z | v r d S �"�j � |� � t j d| |� � |S )N)z.svn/zCVS/�/zCopying %s to %s)�
startswithr# �appendr �debug)�src�dst�skipr s �r �skimmerz*install_egg_info.copytree.