OwlCyberSecurity - MANAGER
Edit File: bdist_msi.cpython-36.opt-2.pyc
3 ��2a��������������������@���s����d�dl�Z�d�dlZd�dlmZ�d�dlmZ�d�dlmZ�d�dlm Z �d�dl mZ�d�dlm Z �d�dlmZ�d�dlZd�d lmZmZmZ�d�d lmZmZmZmZ�G�dd��de�ZG�d d��de�ZdS�)�����N)�Command)�remove_tree)�get_python_version)� StrictVersion)�DistutilsOptionError)�get_platform)�log)�schema�sequence�text)� Directory�Feature�Dialog�add_datac���������������@���sB���e�Zd�Zdd��Zdd��Zddd�Zdd d�Zdd d�Zdd��ZdS�)�PyDialogc�������������O���s>���t�j|�f|����|�jd�}d|�d�}|�jdd||�jd��d�S�)N�$�������iH��Z BottomLiner���)r����__init__�h�line�w)�self�args�kwZrulerZbmwidth��r����./opt/alt/python36/lib64/python3.6/bdist_msi.pyr������s���� zPyDialog.__init__c���������� ���C���s���|�j�ddddddd|���d�S�)N�Title����� ���i@���<���i��z{\VerdanaBold10}%s)r���)r����titler���r���r���r ���#���s����zPyDialog.title�Back����c���������� ���C���s,���|r d}nd}|�j�|d|�jd�dd|||�S�)N����r"������������8�������)� pushbuttonr���)r���r ����next�name�active�flagsr���r���r����back*���s����z PyDialog.back�Cancelc���������� ���C���s,���|r d}nd}|�j�|d|�jd�dd|||�S�)Nr#���r"���i0��r%���r&���r'���)r(���r���)r���r ���r)���r*���r+���r,���r���r���r����cancel5���s����zPyDialog.cancel�Nextc���������� ���C���s,���|r d}nd}|�j�|d|�jd�dd|||�S�)Nr#���r"��������r%���r&���r'���)r(���r���)r���r ���r)���r*���r+���r,���r���r���r���r)���@���s����z PyDialog.nextc���������� ���C���s,���|�j�|t|�j|�d��|�jd�ddd||�S�)N����r%���r&���r'���r#���)r(����intr���r���)r���r*���r ���r)���Zxposr���r���r����xbuttonK���s����zPyDialog.xbuttonN)r!���r"���)r.���r"���)r0���r"���) �__name__� __module__�__qualname__r���r ���r-���r/���r)���r4���r���r���r���r���r������s��� r���c���������������@���s����e�Zd�ZdZdCddde���fdEdGdHdIdJdKdLdMg ZddddgZddd d!d"d#d$d%d&d'd(d)d*d+d,d-d.d/d0d1gZd2Zd3d4��Z d5d6��Z d7d8��Zd9d:��Zd;d<��Z d=d>��Zd?d@��ZdAdB��ZdS�)N� bdist_msiz7create a Microsoft Installer (.msi) binary distribution� bdist-dir=N�1temporary directory for creating the distributionz plat-name=�pz;platform name to embed in generated filenames (default: %s)� keep-temp�kz/keep the pseudo-installation tree around after z!creating the distribution archive�target-version=z!require a specific python versionz on the target system�no-target-compile�c�/do not compile .py to .pyc on the target system�no-target-optimize�o�;do not compile .py to .pyo (optimized) on the target system� dist-dir=�d�-directory to put final built distributions in� skip-build�2skip rebuilding everything (for testing/debugging)�install-script=�Ubasename of installation script to be run after installation or before deinstallation�pre-install-script=�{Fully qualified filename of a script to be run before any files are installed. This script need not be in the distributionz2.0z2.1z2.2z2.3z2.4z2.5z2.6z2.7z2.8z2.9z3.0z3.1z3.2z3.3z3.4z3.5z3.6z3.7z3.8z3.9�Xc�������������C���sF���d�|�_�d�|�_d|�_d|�_d|�_d�|�_d�|�_d�|�_d�|�_d�|�_ d�|�_ d�S�)Nr���)� bdist_dir� plat_name� keep_tempZno_target_compileZno_target_optimize�target_version�dist_dir� skip_build�install_script�pre_install_script�versions)r���r���r���r����initialize_options}���s����zbdist_msi.initialize_optionsc�������������C���s����|�j�dd ��|�jd�kr2|�jd�j}tjj|d�|�_t��}|�j�rP|�j j ��rP||�_|�jr�|�jg|�_|�j�r�|�j j ��r�|�j|kr�t d|f���nt|�j�|�_|�j�dd d��|�jr�t d��|�jr�x2|�j jD�]}|�jtjj|�kr�P�q�W�t d|�j���d�|�_d�S�)NZbdistrT���ZmsizMtarget version can only be %s, or the '--skip-build' option must be specifiedrS���rP���z5the pre-install-script feature is not yet implementedz(install_script '%s' not found in scripts)rT���rT���)rS���rS���)rP���rP���)Zset_undefined_optionsrO����get_finalized_command� bdist_base�os�path�joinr���rR����distribution�has_ext_modulesrW���rT���r����list�all_versionsrV���rU����scripts�basename�install_script_key)r���rZ���Z short_versionZscriptr���r���r����finalize_options����s:���� zbdist_msi.finalize_optionsc�������������C���sz��|�j�s|�jd��|�jddd�}|�j|_|�j�|_�d|_|�jd�}d|_d|_|�jj ��r�|�j }|spdtjd�d���}d |�j |f�}|�jd�}tjj|jd |��|_tjd|�j��|j���tjjdtjj|�jd���|j���tjd=�|�j|�j��|�jj��}|�j|�}tjj|�}tjj|��r"tj|��|�jj }|j!} | �s<|j"} | �sFd } |j#��} dt$| �j%�}|�jj��}|�j �r~d|�j |f�}nd|�}t&j'|t(|t&j)��|| �|�_*t&j+|�j*t,��d| fg} |j-�p�|j.}|�r�| j/d|f��|j0�r�| j/d|j0f��| �rt1|�j*d| ��|�j2���|�j3���|�j4���|�j5���|�j*j6���t7|�jd��r^d|�j �pJd|f}|�jj8j/|��|�j9�svt:|�j|�j;d��d�S�)N�build�installr"���)Zreinit_subcommandsr����install_libz%d.%d����z.%s-%s�libzinstalling to %sZPURELIBZUNKNOWNz%d.%d.%dzPython %s %sz Python %sZDistVersionZ ARPCONTACTZARPURLINFOABOUT�Property� dist_filesr8����any)�dry_run)<rT���Zrun_commandZreinitialize_commandrO����prefixZwarn_dir�compile�optimizer^���r_���rR����sys�version_inforP���rY���r[���r\���r]���Z build_baseZ build_libr����infoZensure_finalized�insert�runZmkpathrS����get_fullname�get_installer_filename�abspath�exists�unlink�metadata�authorZ maintainerZget_versionr����version�msilibZ init_databaser ���Zgen_uuid�dbZ add_tablesr ���Zauthor_emailZmaintainer_email�appendZurlr����add_find_python� add_files�add_scripts�add_ui�Commit�hasattrrl���rQ���r���rn���)r���rg���rh���rR���Zplat_specifierrf����fullname�installer_namer|���r}���r~���ZsversionZproduct_nameZpropsZemail�tupr���r���r���rv�������s|���� � z bdist_msi.runc���������� ���C���s*��|�j�}tjd�}tjj|�j�}t||d�|dd�}t|ddddddd�}||d fg}x�|�j |�j g�D�]t}d|�}d|��} } d}||�j kr�d }d} nd|�}d} t|| ||d| |d�}t|||||| �}|j|||f��qbW�|j���i�}�x2|D��](\}}}|g}�x|�r|j ��}x�tj|j�D�]�}tjj|j|�}tjj|��rzd |j|�|f�}||�} t||||| |�}|j|��n�|j�s�|j|j|d��||k�r�|j|��}||<�||�jk�r|�j�r�td|���d|�|�_n*||�}t|�j�d||�|j|d�|jfg���q W��qW�|j���q�W�|j|��d�S�)NZ distfiles� TARGETDIRZ SourceDir�PythonZ Everythingr���r"���)Z directory��zPython from another locationri���zPython %s from registryz%s|%szMultiple files with name %sz[#%s]Z DuplicateFile)r����r���ZCABr[���r\���ry���rO���r���r ���rW���� other_versionr����r�����pop�listdirZabsoluter]����isdirZ make_shortZ componentZstart_componentZlogicalZadd_filerU���rd���r���r���Zcommit)r���r����ZcabZrootdir�root�f�itemsr~����targetr*����defaultZdescr ����level�dir�seenZfeatureZtodo�fileZafileZshortZnewdir�keyr���r���r���r���� ��s\���� &zbdist_msi.add_filesc�������������C���s���d}�xv|�j�D��]j}d|�}d|�}d|�}d|�}d|�}d|�}d|�} d |�} d |�}d|�}tjrpd} nd} t|�jd|d|d�| f|d|d�| fg��t|�jd||f||fg��t|�jd|d|d|�d�f| d |d|�d�f| d!|d|�d�fg��t|�jd|||f| ||d�f| d�|d�fg��t|�jd|||f| ||d�f| d�|d�fg��t|�jdd|�dd|�fg��|d7�}qW�d�S�)"Ni���z)SOFTWARE\Python\PythonCore\%s\InstallPathzpython.machine.zpython.user.zPYTHON.MACHINE.zPYTHON.USER.ZPythonFromMachineZPythonFromUserZ PythonExer�����PYTHONri�������Z RegLocatorr"���Z AppSearch�CustomAction�3��������[�]z]\python.exe�InstallExecuteSequence�InstallUISequenceZ Conditionr����r���z NOT TARGETDIR��������i3��i3��i3��)rW���r���ZWin64r���r����)r����start�verZinstall_pathZmachine_regZuser_regZmachine_propZ user_propZmachine_actionZuser_actionZ exe_actionZtarget_dir_prop�exe_propZTyper���r���r���r����C��sJ����zbdist_msi.add_find_pythonc�������������C���s����|�j�rnd}xb|�j|�jg�D�]P}d|�}d|�}t|�jd|d||�jfg��t|�jd|d|�|fg��|d7�}qW�|�jr�tjj |�j d �}t|d �}|jd��|jt|�j�j ����|j���t|�jdd tj|�fg��t|�jddg��t|�jddg��d�S�)Ni���zinstall_script.r����r�����2���r����z&Python%s=3r"���zpreinstall.batr���zrem =""" %1 %0 exit """ �Binary� PreInstallri���� NOT Installed����)r����ri���r����N)r����r����r����)rU���rW���r����r���r����rd���rV���r[���r\���r]���rO����open�write�read�closer���r����)r���r����r����Zinstall_actionr����Zscriptfnr����r���r���r���r����y��s,���� zbdist_msi.add_scriptsc�������������C���s� ��|�j�}d�}}d}d}d}d}d}d} t|dd�d�d�d�d�d�g��t|dd�d�d�d�g��t|d d�d�d�d��d�g��t|d/tj��t|d0tj��t|d1||||||d2d2d2�} | jd3��| jd4d2dd5��| jd6d7dd5��| jd8d9d:d;d<d=d>��| jd?d9d@d;dAd=dB��| j d2d6d2dC�}|j dDdE��t|dF||||||d2d2d2�}|jdG��|jd4d2dd5��|jd6d7dd5��|jd8d9d:d;d<d=dH��|jd?d9d@d;dAd=dB��|j d2d6d2dC�}|j dDdE��t|dI||||||d2d2d2�} | jdJ��| jd4d2dd5��| jd6d7dd5��| jdKd9dLd;dAd=dB��| j d2d6d2dC�}|j dDdM��t|dN||||dO|dPdPdPdQdR�}|jdSd9dTdUd9d=dV��|jdKdAdWdXdAd=dY��|jdZdAd[d\ddd]��|jd^d_dAd`d\dadbdcd�d�d���|jdEdddEdC�}|j dDdE��|j dddPdddC�}|j dDdd��|jdPdEdPdC�}|j dDdP��t|dddd\dedf|dgd�d��}|jdgdddXdhddi��|j djdkdldmdnddod��j dDdp��|j dqdrdldmdnddsd��j dDdt��|j duddldmdnddvd��j dDdw��|j dxdydldmdndd6d��j dDdz��|j d{dmdldmdndddd��j dDd|��|j d}d~dldmdnddd��j dDd���|j d�d�dldmdnddPd��j dDd���t|d�ddd�d�d|dododo�}|jdZdhd9d�d�dd���|j dsdld�d�d�ddsdo�}|j dDdE��|j dod�d�d�d�ddods�}|j dDdM��t|d�ddd�d�||dMdMdM�}|jdZdhd9d�d�dd���|j dMd�d�d�d�ddMd��}|j dDdE��t|d!||||||d6d6d6�}|jdKd9d:d;d�d=d���|jd���|jd/d9d�d;dAd=d��}|jd/dZ��|jd�d9d�d;d�d=d��}|jd�dZ��|jd7d�dd5��|j d�d�dd5��|jd6d��}|j d�d���t|d'||||||d�d�d6�}|jd���|jd�d9d�ddAdd�|�jj�����|jd4d�dd5��|j d�d6�}d}|j d�d�|d���x:|�j|�jg�D�](}|d7�}|j d�d�|�d�|�|d����qW�|j d�d�|d�d���|j dDdM|d��d���|jd6d��}|j d�d���|jd�d�d9d�ddkdd�d�d�d��}|j d�d���|�j}d�|�}d�|�}|jd�d9dUdd9dd��}|jd�|��|jd�|��|jd�|��|jd�|��|jd�d�d9d�dd�dd�|�d�d�d��}|jd�|��|jd�|��|jd�|��|jd�|��t|d�||||||d�d�d�dQdR�}|jdSd9dTdUd9d=d���|jdKdAdAdXdAd=d���|jdZdAd�d\d�dd���|jd�d�dAd�d\d�d�d�d�d�d���|jd�dd�dj dDdM��t|d$||||||d�d�d6�}|jdă�|jd�d9d�d�ddddid�� }|jddd�d�dAdƃ�|jd�dd�d�dAdɃ�|jd7d�dd5��|j d�d6�}|j d�d�d�d��|j dDdMd�d���|jd6dÃ}|j d�d���t|d-||||||d6d6d6dQdR�}|jdSdAd9dUd9d=d̃�|jdZd�d�dd�ddσ�|jd�d�d�d�dAddу�|jd/d:d�|d:�dAdd��}|jd/dZ��|jd�d�d�dkddd�d�d�d�d��}|jd�dփ�|jd4d�dQd5��|j d�d6dQd5��|jd6d7�j d�d���t|d*||||||d�d�d6�}|jd׃�|jd�d9d�d\dyddڃ�|jd�d9d�d\d�dddid�� }|jddd�dUd�dރ�|jd�dd�dUd�d��|jd4d�dQd5��|j d2d6�}|j d�dd�dŃ�|j d�d�d�dT��|j d�d�d�db��|j d�dd�d��|j d�dd�d��|j d�d�d�d��|j d�d�d�d��|j d�dd�d��|j dDdMd�dA��|jd6dۃj d�d���d�S�(��Nr����ir��i,��z[ProductName] Setupr#���r"���� ���rk���� DefaultUIFont�DlgFont8�ErrorDialog�ErrorDlg� Progress1�Install� Progress2�installs�MaintenanceForm_Action�Repair� WhichUsers�ALLZ TextStyle�Tahoma� ���r����DlgFontBold8����� VerdanaBold10�Verdanar����VerdanaRed9����r����� PrepareDlg�(Not Privileged or Windows9x or Installed����� WhichUsersDlg�.Privileged and not Windows9x and not Installed�����SelectFeaturesDlg� Not Installed�����MaintenanceTypeDlg�,Installed AND NOT RESUME AND NOT Preselected�����ProgressDlg����� ActionText�UITextZ FatalErrorZFinishz)[ProductName] Installer ended prematurelyz< Back)r+���r.���r!���ZDescription1r����F���i@���P���i��z�[ProductName] setup ended prematurely because of an error. Your system has not been modified. To install this program at a later time, please run the installation again.ZDescription2��������z.Click the Finish button to exit the Installer.)r*���Z EndDialogZExitZUserExitz'[ProductName] Installer was interruptedz�[ProductName] setup was interrupted. Your system has not been modified. To install this program at a later time, please run the installation again.Z ExitDialogz&Completing the [ProductName] InstallerZDescription�����ZReturnZ FilesInUse����ZRetryF)Zbitmapr������������z{\DlgFontBold8}Files in Use����i��z8Some files that need to be updated are currently in use.ZText�7���iJ��z�The following applications are using files that need to be updated by this setup. Close these applications and then click Retry to continue the installation or Cancel to exit it.ZListZListBox�k�����������ZFileInUseProcess�Ignore�e���i��Z ErrorText�0���r�����N�x����H����Q�������ZNoZErrorNo�Y�����ZYesZErrorYes�AZAbortZ ErrorAbort�C�*���ZErrorCancel�IZErrorIgnore�O����ZOkZErrorOk�R�����Z ErrorRetryZ CancelDlgi���U������������z;Are you sure you want to cancel [ProductName] installation?�9���r&���r'�������ZWaitForCostingDlgzRPlease wait while the installer finishes determining your disk space requirements.�f����(���zOPlease wait while the Installer prepares to guide you through the installation.z&Welcome to the [ProductName] Installer�n���zPondering...Z ActionData����r0���ZSpawnDialogzSelect Python InstallationsZHintz9Select the Python locations where %s should be installed.zNext >z[TARGETDIR]z[SourceDir])Zorderingz [TARGETDIR%s]z FEATURE_SELECTED AND &Python%s=3ZSpawnWaitDialogri���ZFeaturesZ SelectionTreer���ZFEATUREZPathEditz[FEATURE_SELECTED]�1z!FEATURE_SELECTED AND &Python%s<>3ZOtherz$Provide an alternate Python locationZEnableZShowZDisableZHide�����r����r����ZDiskCostDlgZOKz&{\DlgFontBold8}Disk Space RequirementszFThe disk space required for the installation of the selected features.�5���a��The highlighted volumes (if any) do not have enough disk space available for the currently selected features. You can either remove some files from the highlighted volumes, or choose to install less features onto local drive(s), or select different destination drive(s).Z VolumeListZVolumeCostList�d�������i��z{120}{70}{70}{70}{70}g�������?ZAdminInstallzGSelect whether to install [ProductName] for all users of this computer.����zInstall for all usersZJUSTME����zInstall just for mez [ALLUSERS]zWhichUsers="ALL"z({\DlgFontBold8}[Progress1] [ProductName]�#����A���zYPlease wait while the Installer [Progress2] [ProductName]. This may take several minutes.ZStatusLabelzStatus:ZProgressBari��z Progress doneZSetProgressZProgressz)Welcome to the [ProductName] Setup WizardZBodyText�?���z:Select whether you want to repair or remove [ProductName].ZRepairRadioGroup�l���r����z&Repair [ProductName]ZRemover���zRe&move [ProductName]z[REINSTALL]zMaintenanceForm_Action="Repair"z[Progress1]Z Repairingz[Progress2]ZrepairsZ Reinstallz[REMOVE]zMaintenanceForm_Action="Remove"����ZRemoving����Zremoves� �������z MaintenanceForm_Action<>"Change")r����r����)r����r����)r����r����)r����r����)r����r����)r����r����)r����r����r����Nr���)r����r����r����Nr"���)r����r����r���Nr"���)r����r����r����r����r���)r����r����r����)r����r����r����)r����r����r����)r����r����r����)r����Nr����)r����r���r���r����r����r���r ���r-���r/���r)���ZeventZcontrolr���r(����mappingr^���rw���rW���r����Z conditionr4���Z radiogroup�add)r���r�����x�yr���r���r ���ZmodalZmodelessZtrack_disk_spaceZfatalr@���Z user_exitZexit_dialogZinuse�errorr/���ZcostingZprepZseldlg�orderr~���r����Zinstall_other_condZdont_install_other_condZcostZ whichusers�gZprogressZmaintr���r���r���r�������s���� zbdist_msi.add_uic�������������C���s<���|�j�rd||�j|�j�f�}nd||�jf�}tjj|�j|�}|S�)Nz%s.%s-py%s.msiz %s.%s.msi)rR���rP���r[���r\���r]���rS���)r���r����Z base_namer����r���r���r���rx������s����z bdist_msi.get_installer_filename)r9���Nr:����Pkeep the pseudo-installation tree around after creating the distribution archive)r<���r=���r���6require a specific python version on the target system)r>���Nr��)r?���r@���rA���)rB���rC���rD���)rE���rF���rG���)rH���NrI���)rJ���NrK���)rL���NrM���)r5���r6���r7����descriptionr���Zuser_optionsZboolean_optionsra���r����rX���re���rv���r����r����r����r����rx���r���r���r���r���r8���S���sR�������������� ([66&��@r8���)rr���r[���Zdistutils.corer���Zdistutils.dir_utilr���Zdistutils.sysconfigr���Zdistutils.versionr���Zdistutils.errorsr���Zdistutils.utilr���Z distutilsr���r���r ���r ���r���r���r ���r���r���r���r8���r���r���r���r����<module> ���s���>