B 0c@s@ddlZddlmZddlmZddlmZGdddeZdS)N)Command)log)ST_MODEc@sLeZdZdZddddgZddgZdd Zd d Zd d ZddZ ddZ dS)install_scriptsz%install scripts (Python or otherwise))z install-dir=dzdirectory to install scripts to)z build-dir=bz'build directory (where to install from))forcefz-force installation (overwrite existing files))z skip-buildNzskip the build stepsrz skip-buildcCsd|_d|_d|_d|_dS)Nr) install_dirr build_dir skip_build)selfrF/opt/alt/python37/lib64/python3.7/distutils/command/install_scripts.pyinitialize_optionssz"install_scripts.initialize_optionscCs |dd|dddddS)NZbuild) build_scriptsr install)rr )rr)r r )Zset_undefined_options)r rrrfinalize_options!s  z install_scripts.finalize_optionscCs|js|d||j|j|_tjdkrxT|D]H}|j rNt d|q6t |t dBd@}t d||t||q6WdS)Nrposixzchanging mode of %simizchanging mode of %s to %o)r Z run_commandZ copy_treer r outfilesosname get_outputsZdry_runrinfostatrchmod)r filemoderrrrun)s  zinstall_scripts.runcCs |jjp gS)N)Z distributionZscripts)r rrr get_inputs8szinstall_scripts.get_inputscCs |jpgS)N)r)r rrrr;szinstall_scripts.get_outputsN) __name__ __module__ __qualname__ descriptionZ user_optionsZboolean_optionsrrrrrrrrrrsr)rZdistutils.corerZ distutilsrrrrrrrrs