]"@sddlZddlZddlmZddlTddlmZddlmZddl m Z ddl m Z dZ d d Zdadad3Zd4Zd.d/Zdd0d1d2ZdS)5N)DEBUG)*) Distribution)Command) PyPIRCCommand) Extensionzusage: %(script)s [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: %(script)s --help [cmd1 cmd2 ...] or: %(script)s --help-commands or: %(script)s cmd --help cCstjj|}ttS)N)ospathbasenameUSAGEvars) script_nameZscriptr)/opt/alt/python35/lib64/python3.5/core.py gen_usage sr distclassr script_argsoptionsnameversionauthor author_email maintainermaintainer_emailurllicense descriptionlong_descriptionkeywords platforms classifiers download_urlrequiresprovides obsoletessources include_dirs define_macros undef_macros library_dirs librariesruntime_library_dirs extra_objectsextra_compile_argsextra_link_args swig_optsexport_symbolsdependslanguagec,Ks|jd}|r|d=nt}d|krNtjjtjd|dd|krt d|nt d|d|fWYdd}~XnXt d kr|S|j t rt d |jt d kr*|Sy|j}WnBtk r~}z"t t|jd |WYdd}~XnXt rt d |jt dkr|S|ry|jWntk rt dYntk r7}z;t rtjjd|fnt d|fWYdd}~XnMttfk r}z't r[nt dt|WYdd}~XnX|S)Nrr rrrzerror in setup command: %szerror in %s setup command: %sinitz%options (after parsing config files):configz error: %sz%options (after parsing command line): commandlineZ interruptedz error: %s z error: %szerror: )getrrr r sysargv_setup_distributionZDistutilsSetupError SystemExit_setup_stop_afterZparse_config_filesrprintZdump_option_dictsZparse_command_lineZDistutilsArgErrorrr Z run_commandsKeyboardInterruptOSErrorstderrwriteZDistutilsErrorZCCompilerErrorstr)ZattrsklassZdistmsgokexcrrrsetup9s`%    '     0    %)rGruncCs|d krtd|f|atj}d|i}i}yvz_|tjd<|dk rr|tjdd s0      q