|8=ƂLdZddlmZ edn #eef$rYnwxYwddlZddlZddl Z ddl m Z ddl mZddl mZddlmZdd lmZdd lmZdd lmZd d lmZejeZ d"ddd#dZ d"d$dZd%dZ d%d Z!d%d!Z"dS)&z7Locations where we look for configs, install stuff, etc) annotations_distutils_hackN)Command) SCHEME_KEYS)installget_python_lib)Scheme)WINDOWS)running_under_virtualenv)get_major_minor_versionF)ignore_config_files dist_namestruserboolhome str | Nonerootisolatedprefixrreturndict[str, str]cddlm}d|i}|rdg|d<||} |sr | n\#t$rO| } t ddd| DYnwxYwd } | d d } | J| } |r|rJd |d||r|rJd|d||p| j | _ |s|rd| _ |p| j | _ |p| j | _ |p| j | _ | i} tD]}t| d|z| |<d| d vr"| | j| jdt'r|r|}n|r| j}n| j }t*j|dddt/|| d<|st*jt*j| dd}t*j||dd | d<| S)z+ Return a distutils install scheme r) Distributionnamez --no-user-cfg script_argsz6Ignore distutils configs in %s due to encoding errors.z, c3TK|]#}tj|V$dS)N)ospathbasename).0ps t/builddir/build/BUILD/cloudlinux-venv-1.0.10/venv/lib/python3.11/site-packages/pip/_internal/locations/_distutils.py z#distutils_scheme..?s2==!"'**1--======NrT)createzuser=z prefix=zhome=install_ install_lib)purelibplatlibincludesitepythonheadersr )distutils.distrparse_config_filesUnicodeDecodeErrorfind_config_filesloggerwarningjoinget_command_objrrrrfinalize_optionsrgetattrget_option_dictupdater+r install_userbaser r!r splitdriveabspath)rrrrrrrr dist_argsdpathsobjischemekey path_no_drives r%distutils_schemerI$s,+++++-3Y,?I5$3#4 -  YA   " " " "!   ''))E NNH ==u=====       $(C  Id  3 3C ???#&A@@@"@$"@"@"@"@@@ @@@"@$"@"@"@"@@@ ^QVAF t!AH ^QVAF ^QVAFF33ac!122s )))4444 !-AMJJKKK!!F  FF  'FFXFGLL    0,.. 0 0    y  G..rwvi?P/Q/QRRSTUM " T=3D E EF9  Ms6ABBr ct||||||}t|d|d|d|d|dS)a; Get the "scheme" corresponding to the input parameters. The distutils documentation provides the context for the available schemes: https://docs.python.org/3/install/index.html#alternate-installation :param dist_name: the name of the package to retrieve the scheme for, used in the headers scheme path :param user: indicates to use the "user" scheme :param home: indicates to use the "home" scheme and provides the base directory for the same :param root: root under which other directories are re-based :param isolated: equivalent to --no-user-cfg, i.e. do not consider ~/.pydistutils.cfg (posix) or ~/pydistutils.cfg (non-posix) for scheme paths :param prefix: indicates to use the "prefix" scheme and provides the base directory for the same r-r,r1scriptsdata)r-r,r1rKrL)rIr )rrrrrrrFs r% get_schemerMtsY2itT8V L LF y!y!y!y! F^    r'ctjtj}t ratj|d}tj|s tj|d}|Stjdddkr|dddkrdStj|dS)NScriptsbindarwinz/System/Library/z/usr/local/bin) r r!normpathsysrr r8existsplatform)rbin_pys r%get_bin_prefixrYsW  cj ) )Ffi00w~~f%% 1W\\&%00F  |BQB8##ss 7I(I(I 7<< & &&r'c"tdS)NF plat_specificrr'r% get_purelibr^s  . . ..r'c"tdS)NTr[rr]r'r% get_platlibr`s  - - --r')FNNFN)rrrrrrrrrrrrrrrr)rrrrrrrrrrrrrr )rr)#__doc__ __future__r __import__ remove_shim ImportErrorAttributeErrorloggingr rU distutils.cmdrDistutilsCommanddistutils.command.installrrdistutils_install_commanddistutils.sysconfigr pip._internal.models.schemer pip._internal.utils.compatr pip._internal.utils.virtualenvr baser getLogger__name__r6rIrMrYr^r`r]r'r%rss==#""""" J !!--////^$   D  555555111111JJJJJJ..................CCCCCC))))))  8 $ $  M!&MMMMMMd     F''''"////......s (22