Your IP : 172.28.240.42


Current Path : /usr/lib/python2.7/
Upload File :
Current File : //usr/lib/python2.7/platform.pyc



|_c
@s1dZdZdZddlZddlZddlZddlZy
ejZWn/e	k
rej
d]krwd	Zqd
ZnXejdZej
ddd
dZdZejdZejdZejdZd^Zd Zejd!ejZejd"ejZejd#ejZddded$d%Zddded&Zd'd_d(YZd)dd*Zdd+Zejd,Zdddd`d-Z dd.Z!ddddd/Z"dd0Z#d1Z$d2Z%d3Z&ddadd4Z'd5Z(dddbdcd6Z)d7Z*d8Z+dd9Z,e-ej.d:sej.j/ej.j0ej1ej.j2d;Z3nej.j4Z3d<Z5dd=Z6dd>Z7iddd6ded6dfd6Z8ejdBj9Z:ej
dddCZ;da<dDZ=dEZ>dFZ?dGZ@dHZAdIZBdJZCejdKZDejdLZEejdMZFiZGddNZHdOZIdPZJdQZKdRZLdSZMdTZNdUZOiZPdVdVdWZ
eQdXkr-dYejRkpdZejRkZSd[ejRkod\ejRkZTe
eTeSGHejUdVndS(gs8 This module tries to retrieve as much platform-identifying data as
    possible. It makes this information available via function APIs.

    If called from the command line, it prints the platform
    information concatenated as single string to stdout. The output
    format is useable as part of a filename.

s
    Copyright (c) 1999-2000, Marc-Andre Lemburg; mailto:mal@lemburg.com
    Copyright (c) 2000-2010, eGenix.com Software GmbH; mailto:info@egenix.com

    Permission to use, copy, modify, and distribute this software and its
    documentation for any purpose and without fee or royalty is hereby granted,
    provided that the above copyright notice appear in all copies and that
    both that copyright notice and this permission notice appear in
    supporting documentation or portions thereof, including modifications,
    that you make.

    EGENIX.COM SOFTWARE GMBH DISCLAIMS ALL WARRANTIES WITH REGARD TO
    THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
    FITNESS, IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL,
    INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING
    FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
    NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
    WITH THE USE OR PERFORMANCE OF THIS SOFTWARE !

s1.0.7iNtdostwin32twin16tos2tNULs	/dev/nullsC(__libc_init)|(GLIBC_([0-9.]+))|(libc(_\w+)?\.so(?:\.(\d[0-9.]*))?)ticCs~ttjdr'tjj|}nt|d}|j|}d}xtj||}|s|j|}|sPnd}qNn|j\}}	}
}}}
|r|rd}n|	r|dkrd}|
}q[|
|kr[|
}q[nc|r[|dkr[d}|
r+|
|kr+|
}n|rX|t	||krX||}qXq[n|j
}qN|j||fS(s Tries to determine the libc version that the file executable
        (which defaults to the Python interpreter) is linked against.

        Returns a tuple of strings (lib,version) which default to the
        given parameters in case the lookup fails.

        Note that the function has intimate knowledge of how different
        libc versions add symbols to the executable and thus is probably
        only useable for executables compiled using gcc.

        The file is read and scanned in chunks of chunksize bytes.

    trealpathtrbitlibctglibc(thasattrtostpathRtopentreadt_libc_searchtsearchtgroupstlentendtclose(t
executabletlibtversiont	chunksizetftbinarytpostmtlibcinitR	tglibcversiontsotthreadst	soversion((s/usr/lib/python2.7/platform.pytlibc_vers@
			
cCstjjdrtdj}d}x|D]}tj|}t|dkr1|\}}nq1|dkrtj|}q1|dkr1tj|d}|d}q1q1W|||fStjjdrAtdj}xV|D]K}tj|d}	t|	dkr|	dd	krd	|	d
|fSqWntjj	drtj
d}
xBtt|
d
ddD]$}|
|d
 dkr|
|=qqW|
r|
jd}|
dd
}|||fSn|||fS(s Tries some special tricks to get the distribution
        information in case the default method fails.

        Currently supports older SuSE Linux, Caldera OpenLinux and
        Slackware Linux distributions.

    s/var/adm/inst-log/infotSuSEitMIN_DIST_VERSIONt
DIST_IDENTt-s/etc/.installedit	OpenLinuxis/usr/lib/setupiisslack-version-t	slackware(
RRtexistsR
t	readlineststringtsplitRtstriptisdirtlistdirtrangetsort(tdistnameRtidtinfotlinettvttagtvaluetvaluestpkgtverfilestn((s/usr/lib/python2.7/platform.pyt_dist_try_harders>	


"#
s(\w+)[-_](release|version)s'(.+) release ([\d.]+)[^(]*(?:\((.+)\))?s1([^0-9]+)(?: release )?([\d.]+)[^(]*(?:\((.+)\))?R#tdebiantfedoratredhattcentostmandraketmandrivatrocksR(t	yellowdogtgentootUnitedLinuxt
turbolinuxcCsd}d}tj|}|dk	r7t|jStj|}|dk	rbt|jStjtj|}|r|d}t	|dkr|d}qnd||fS(NRii(
t_lsb_release_versiontmatchtNonettupleRt_release_versionR+R,R-R(t	firstlineRR3Rtl((s/usr/lib/python2.7/platform.pyt_parse_release_files
s(?:DISTRIB_ID\s*=)\s*(.*)s(?:DISTRIB_RELEASE\s*=)\s*(.*)s(?:DISTRIB_CODENAME\s*=)\s*(.*)icCsytdd}x|D]}tj|}|rL|jdj}ntj|}|ry|jdj}	ntj|}|r|jdj}
qqW|r|	r||	|
fSWnttfk
rnXyt	j
d}Wnt	jk
r|||fSX|jxd|D]L}t
j|}|dk	r#|j\}
}|
|kro|
}Pqoq#q#Wt|||Std|d}|j}|jt|\}
}}|
r|r|
}n|r|}n|r|}n|||fS(s Tries to determine the name of the Linux OS distribution name.

        The function first looks for a distribution release file in
        /etc and then reverts to _dist_try_harder() in case no
        suitable files are found.

        supported_dists may be given to define the set of Linux
        distributions to look for. It defaults to a list of currently
        supported Linux distributions identified by their release file
        name.

        If full_distribution_name is true (default), the full
        distribution read from the OS is returned. Otherwise the short
        name taken from supported_dists is used.

        Returns a tuple (distname,version,id) which default to the
        args given as parameters.

    s/etc/lsb-releasetrUis/etcs/etc/trN(R
t_distributor_id_file_reRtgroupR-t_release_file_ret_codename_file_retEnvironmentErrortUnboundLocalErrorRR/terrorR1t_release_filenameRJRKRR=treadlineRRP(R2RR3tsupported_diststfull_distribution_namet	etclsbrelR5Rt_u_distnamet
_u_versiont_u_idtetctfilet	_distnametdummyRRNt_versiont_id((s/usr/lib/python2.7/platform.pytlinux_distribution'sP



			cCst|||d|ddS(sQ Tries to determine the name of the Linux OS distribution name.

        The function first looks for a distribution release file in
        /etc and then reverts to _dist_try_harder() in case no
        suitable files are found.

        Returns a tuple (distname,version,id) which default to the
        args given as parameters.

    R\R]i(Rh(R2RR3R\((s/usr/lib/python2.7/platform.pytdistrst_popencBsbeZdZdZdZdZdZdddZdZ	dZ
ejej
dZeZRS(s Fairly portable (alternative) popen implementation.

        This is mostly needed in case os.popen() is not available, or
        doesn't work as advertised, e.g. in Win9X GUI programs like
        PythonWin or IDLE.

        Writing to the pipe is currently not supported.

    RRRcCst|dkrtdnddl}|j|_}tj|d|t|d|_||_||_	dS(NRRs)popen()-emulation only supports read modeis > %sR(
t
ValueErrorttempfiletmktempttmpfileRtsystemR
tpipetbufsizetmode(tselftcmdRrRqRlRn((s/usr/lib/python2.7/platform.pyt__init__s	cCs
|jjS(N(RpR(Rs((s/usr/lib/python2.7/platform.pyRscCs |jdk	r|jjSdS(N(RqRKRpR*(Rs((s/usr/lib/python2.7/platform.pyR*scCsV|jr|jj}nd}|jrRy||jWqR|k
rNqRXn|S(Ni(RpRRn(RstremoveRYtrc((s/usr/lib/python2.7/platform.pyRs		
N(t__name__t
__module__t__doc__RnRKRpRqRrRuRR*RtunlinkRYRt__del__(((s/usr/lib/python2.7/platform.pyRjs
		RRcCsd}tjjdddkrQyddl}Wntk
rDqQX|j}n|dkrttdrtj}tj	dkry|dWqtj
k
rt}qXqqt}n|dkr|||S||||SdS(s! Portable popen() interface.
    tOSRt
Windows_NTiNtpopenR(RKRtenvirontgett	win32pipetImportErrorRR
tsystplatformRYRj(RtRrRqRR((s/usr/lib/python2.7/platform.pyRs&
		
cCs~tj|d}|r(|j|nytt|}Wntk
rT|}nXtt|}tj|d d}|S(s Normalize the version and build strings and return a single
        version string using the format major.minor.build (or patchlevel).
    t.i(R+R,tappendtmaptintRktstrtjoin(RtbuildROtintststrings((s/usr/lib/python2.7/platform.pyt
_norm_versions

s'(?:([\w ]+) ([\w.]+) .*\[.* ([\d.]+)\])c	Cs8tj|kr|||fSxdD]o}y7t|}|j}|jr_tjdnWn.tjk
r{}q#q#tk
r}q#q#XPq#W|||fStj	|}t
j|}|dk	r+|j
\}}}|ddkr|d }n|ddkr|d }nt|}n|||fS(	s2 Tries to figure out the OS version used and returns
        a tuple (system,release,version).

        It uses the "ver" shell command for this which is known
        to exists on Windows, DOS and OS/2. XXX Others too ?

        In case this fails, the given parameters are used as
        defaults.

    tverscommand /c vers
cmd /c verscommand failediR(Rscommand /c vers
cmd /c verN(RRRRRRRYtIOErrorR+R-t_ver_outputRJRKRR(	RotreleaseRtsupported_platformsRtRpR4twhyR((s/usr/lib/python2.7/platform.pyt_syscmd_vers0




cCs]yddlm}Wn&tk
r<ddl}|j}nXy|||SWn|SXdS(se Read a value for name from the registry key.

        In case this fails, default is returned.

    i(tRegQueryValueExN(twin32apiRRt_winregtQueryValueEx(tkeytnametdefaultRR((s/usr/lib/python2.7/platform.pyt_win32_getvalue-s

cCsyTddl}ddlm}m}m}m}ddlm}	m}
m}m	}Wnt
k
rytjWnt
k
r||||fSXddl}
tj}|
j}|
j}|
j}|
j}	d}d}
d}d}d}nX|}|\}}}}}d|||d	@f}t|d
rQ|jdkrrd|j}qrn!|d
 dkrrd|d
}n||krd}|dkr|dkrd}q|dkrd}q|dkrd}qd}q|dkrd}qn||
kr^d}|dkrd}q|dkrk|dkr8d}q[|dkrMd}q[|dkrbd}q[d}q|d krt|d!r|j}nl|}yR||	|}||d"\}}||kr|jd#dkr|}nWntk
rnX|dkr(||krd$}qXd%}q[|dkrR||krId&}qXd'}q[d(}qn)|swd)||f}n||||fSy ||	|}||d*Wn||||fSXt|d+d-d}t|d,|dfd}t||}||||||fS(.s  Get additional version information from the Windows Registry
        and return a tuple (version,csd,ptype) referring to version
        number, CSD level (service pack), and OS type (multi/single
        processor).

        As a hint: ptype returns 'Uniprocessor Free' on single
        processor NT machines and 'Multiprocessor Free' on multi
        processor machines. The 'Free' refers to the OS version being
        free of debugging code. It could also state 'Checked' which
        means the OS version uses debugging code, i.e. code that
        checks arguments, ranges, etc. (Thomas Heller).

        Note: this function works best with Mark Hammond's win32
        package installed, but also on Python 2.3 and later. It
        obviously only runs on Win32 compatible platforms.

    iN(RtRegOpenKeyExtRegCloseKeytGetVersionEx(tHKEY_LOCAL_MACHINEtVER_PLATFORM_WIN32_NTtVER_PLATFORM_WIN32_WINDOWStVER_NT_WORKSTATIONiiis%i.%i.%iitservice_packRsSP%si
s
Service Pack tSPs)SOFTWARE\Microsoft\Windows\CurrentVersioniit95i
t98iZtMetpostMeit2000s,SOFTWARE\Microsoft\Windows NT\CurrentVersiontNTtXPt
2003Servertpost2003itproduct_typetProductNametServertVistat
2008Servert7t2008ServerR2tpost2008Servers%i.%it
SystemRoottCurrentBuildNumbertCurrentType(Ri(RRRRRtwin32conRRRRRRtgetwindowsversiontAttributeErrorRRt	OpenKeyExtCloseKeyR
Rtservice_pack_majorRtfindtWindowsErrorRR(RRtcsdtptypeRRRRRRRRRRt
VER_NT_SERVERtREG_SZtwinvertmajtmintbuildnotplattregkeyRRRttypet	keyCurVerR((s/usr/lib/python2.7/platform.pyt	win32_ver@s"&

					
										!

				

cCs{ddlm}ddl}g}|j}xI|D]A}y|||Wq2t|jfk
rr||q2Xq2W|S(Ni(tgestalt(RtMacOSRtRuntimeErrortError(t	selectorsRRRRORtselector((s/usr/lib/python2.7/platform.pyt_mac_ver_lookups	
cCst|dS(Ni(thex(tbcd((s/usr/lib/python2.7/platform.pyt_bcd2strsc
Csyddl}ddl}Wntk
r0dSXtd\}}|r|d@d?}|d@d?}|d	@}||fdkrtd\}}}d|||f}qdt|||f}n|ridd6dd6dd
6j|d}nd}	||	|fS(s
        Thanks to Mark R. Levinson for mailing documentation links and
        code examples for this function. Documentation for the
        gestalt() API is available online at:

           http://www.rgaros.nl/gestalt/
    iNtsysvtsysaiiiiii
tsys1tsys2tsys3s%i.%i.%is%s.%i.%it68kitPowerPCiti386R(ssysvssysa(i
i(RRR(RRR(RRRRKRRR(
RRRRtmajortminortpatchRtmachinetversioninfo((s/usr/lib/python2.7/platform.pyt_mac_ver_gestalts(	


cCsd}tjj|sdSyddl}Wntk
r@dSX|j|}|d}d	}tjd}|d
krd}n|||fS(Ns0/System/Library/CoreServices/SystemVersion.plistitProductVersionRitppcsPower MacintoshR(RRR(sppcsPower Macintosh(RRR)RKtplistlibRt	readPlisttuname(tfnRtplRRR((s/usr/lib/python2.7/platform.pyt_mac_ver_xmls

	cCs?t}|dk	r|St}|dk	r2|S|||fS(s; Get MacOS version information and return it as tuple (release,
        versioninfo, machine) with versioninfo being a tuple (version,
        dev_stage, non_release_version).

        Entries which cannot be determined are set to the paramter values
        which default to ''. All tuple entries are strings.
    N(RRKR(RRRR4((s/usr/lib/python2.7/platform.pytmac_ver/s		cCsPddlm}y'|j|}|dkr2|S|SWntk
rK|SXdS(Ni(tSystem(t	java.langRtgetPropertyRKR(RRRR8((s/usr/lib/python2.7/platform.pyt
_java_getpropHs
cCsyddl}Wntk
r0||||fSXtd|}td|}|\}}}td|}td|}td|}|||f}|\}}	}
td|
}
td	|}td
|	}	||	|
f}||||fS(sV Version interface for Jython.

        Returns a tuple (release,vendor,vminfo,osinfo) with vminfo being
        a tuple (vm_name,vm_release,vm_vendor) and osinfo being a
        tuple (os_name,os_version,os_arch).

        Values which cannot be determined are set to the defaults
        given as parameters (which all default to '').

    iNsjava.vendorsjava.versionsjava.vm.namesjava.vm.vendorsjava.vm.versionsjava.os.archsjava.os.namesjava.os.version(RRR(Rtvendortvminfotosinfotjavatvm_namet
vm_releaset	vm_vendortos_namet
os_versiontos_arch((s/usr/lib/python2.7/platform.pytjava_verSs"

cCs|dkrd|||fS|dkr|dkrB|||fStj|d}|ryt|d}Wntk
rqX|d}t||d<tj|d}n|dkrd	}qd	}nC|d
krd}|r|d}qd
}n|dkrd}n|||fS(s Returns (system,release,version) aliased to common
        marketing names used for some systems.

        It also does some reordering of the information in some cases
        where it would otherwise cause confusion.

    tRhapsodysMacOS X ServertSunOSt5Riit6tSolaristIRIX64tIRIXs (64bit)t64bitRRtWindows(swin32R(R+R,RRkRR(RoRRROR((s/usr/lib/python2.7/platform.pytsystem_aliasvs2	


		
		cGs%tjttjtt|d}tj}||dd}||dd}||dd}||dd}||dd}||dd}||d	d}||d
d}||dd}x+||d
d}||krPn|}qx|ddkr |d }qW|S(sq Helper to format the platform string in a filename
        compatible format e.g. "system-version-machine".
    R&t t_t/s\t:t;t"t(t)tunknownRs--i(R+RRR-tfilterRtreplace(targsRRtcleaned((s/usr/lib/python2.7/platform.pyt	_platforms,				cCsOyddl}Wntk
r$|SXy|jSWn|jk
rJ|SXdS(s8 Helper to determine the node name of this machine.
    iN(tsocketRtgethostnameRY(RR((s/usr/lib/python2.7/platform.pyt_nodes
tabspathcCs+||s!|||}n||S(N((RtisabsRtgetcwdtnormpath((s/usr/lib/python2.7/platform.pyt_abspathscCs_t|}xLtjj|rZtjjtjjtjj|tj|}qW|S(sT In case filepath is a symlink, follow it until a
        real file is reached.
    (R RRtislinkRRtdirnametreadlink(tfilepath((s/usr/lib/python2.7/platform.pyt_follow_symlinkss
	1cCstjdkr|Sytjd|tf}Wnttjfk
rM|SXtj|j	}|j
}|s||r|S|SdS(s. Interface to the system's uname command.
    RRRRsuname %s 2> %sN(Rswin32swin16sos2(RRRRtDEV_NULLRRYR+R-RR(toptionRRtoutputRw((s/usr/lib/python2.7/platform.pyt
_syscmd_unames
cCstjd	kr|St|jdd}ytjd|tf}Wnttjfk
re|SXt	j
|j}|j}|s|r|S|SdS(
s& Interface to the system's file command.

        The function uses the -b option of the file command to have it
        ommit the filename in its output and if possible the -L option
        to have the command follow symlinks. It returns default in
        case the command should fail.

    RRRRRs\"sfile "%s" 2> %sN(sdosswin32swin16sos2(
RRR%RRRR&RRYR+R-RR(ttargetRRR(Rw((s/usr/lib/python2.7/platform.pyt_syscmd_files

t	WindowsPER	tMSDOSs[\s,]c	Cs|sbddl}y|jd}Wn#|jk
rJ|jd}nXt|dd}n|rzt|d}nd}|r|tjkrtjtkrttj\}}|r|}n|r|}qn||fSt	|d}d	|kr	||fSd
|krd}n*d|kr3d
}nd|krHd}nd|kr]d}nTd|krd|kr~d}qd}n*d|krd}nd|krd}n||fS(s Queries the given executable (defaults to the Python interpreter
        binary) for various architecture information.

        Returns a tuple (bits,linkage) which contains information about
        the bit architecture and the linkage format used for the
        executable. Both values are returned as strings.

        Values that cannot be determined are returned as given by the
        parameter presets. If bits is given as '', the sizeof(pointer)
        (or sizeof(long) on Python version < 1.5.2) is used as
        indicator for the supported pointer size.

        The function relies on the system's "file" command to do the
        actual work. This is available on most if not all Unix
        platforms. On some non-Unix platforms where the "file" command
        does not exist and the executable is set to the Python interpreter
        binary defaults from _default_architecture are used.

    iNtPROitbitRiRs32-bitt32bittN32tn32bits64-bitRtELFtPER	R,tCOFFsMS-DOSR-(
tstructtcalcsizeRYRR+RRRt_default_architecturet_architecture_split(	RtbitstlinkageR6tsizeR(tbROtfileout((s/usr/lib/python2.7/platform.pytarchitecture1sN	

								cCsd}tdk	rtSd}ytj\}}}}}Wntk
rTd}nX|sztd|||||frG|rtj}d}d}t}d}nd}|dkrIt	\}}}}	|r|rd}n|s(dtj
krtj
jdd}q(tj
jdd}n|sItj
jd|}qIn|rt|\}}}|dkryd	}q|d
kr|d	krd	}d|d krd
}qd}qn|dkr|s|dkrd}qd}nd	}qG|d dkrGt
\}}
}}d}tj|d}|sD|
}qDqGn|dkr|sf|dkru|}d}nyddl}
Wntk
rqX|
jdd\}}|dkrd}qd}n|stdd}n|dkrd}n|dkrd}n|dkr&d}n|dkr;d}n|dkrPd}n|dkred}n|d
kr|d	krd	}d
}n||||||fatS( si Fairly portable uname interface. Returns a tuple
        of strings (system,node,release,version,machine,processor)
        identifying the underlying platform.

        Note that unlike the os.uname function this also returns
        possible processor information as an additional tuple entry.

        Entries which cannot be determined are set to ''.

    iRiRtPROCESSOR_ARCHITEW6432tPROCESSOR_ARCHITECTUREtPROCESSOR_IDENTIFIERsMicrosoft WindowsR	t	Microsofts6.0iRRR0t16bitiRtJavas, tOpenVMSt0iNsSYI$_CPUitAlphatVAXs-pR(swin32swin16(t_uname_cacheRKRRRRRRRRRRRRR+Rtvms_libRtgetsyiR)(tno_os_unamet	processorRotnodeRRRtuse_syscmd_verRRRRRRKtcsidt
cpu_number((s/usr/lib/python2.7/platform.pyRs


%										
									cCstdS(s Returns the system/OS name, e.g. 'Linux', 'Windows' or 'Java'.

        An empty string is returned if the value cannot be determined.

    i(R(((s/usr/lib/python2.7/platform.pyRoscCstdS(s Returns the computer's network name (which may not be fully
        qualified)

        An empty string is returned if the value cannot be determined.

    i(R(((s/usr/lib/python2.7/platform.pyROscCstdS(s Returns the system's release, e.g. '2.2.0' or 'NT'

        An empty string is returned if the value cannot be determined.

    i(R(((s/usr/lib/python2.7/platform.pyR&scCstdS(s Returns the system's release version, e.g. '#3 on degas'

        An empty string is returned if the value cannot be determined.

    i(R(((s/usr/lib/python2.7/platform.pyR/scCstdS(st Returns the machine type, e.g. 'i386'

        An empty string is returned if the value cannot be determined.

    i(R(((s/usr/lib/python2.7/platform.pyR8scCstdS(s Returns the (true) processor name, e.g. 'amdk6'

        An empty string is returned if the value cannot be
        determined. Note that many platforms do not provide this
        information or simply return the same value as for machine(),
        e.g.  NetBSD does this.

    i(R(((s/usr/lib/python2.7/platform.pyRNAs
sB([\w.+]+)\s*\(#?([^,]+),\s*([\w ]+),\s*([\w :]+)\)\s*\[([^\]]+)\]?s;IronPython\s*([\d\.]+)(?: \(([\d\.]+)\))? on (.NET [\d\.]+)sE([\w.+]+)\s*\(#?([^,]+),\s*([\w ]+),\s*([\w :]+)\)\s*\[PyPy [^\]]+\]?cCs|dkrtj}ntj|d}|dk	r:|S|d dkrd}tj|}|dkrtdt|n|j	\}}}d}d}n>tj
d dkrd}tj|}|dkrtdt|n|j	\}}}}	}
tj
}nd	|krd	}tj|}|dkrbtd
t|n|j	\}}}}	d}nctj|}|dkrtdt|n|j	\}}}}	}d}|d
|	}t
tdr
tj\}
}}nd}d}tj|d}
t|
dkr\|
jdtj|
d}n|||||||f}|t|<|S(s Returns a parsed version of Python's sys.version as tuple
        (name, version, branch, revision, buildno, builddate, compiler)
        referring to the Python implementation name, version, branch,
        revision, build number, build date/time as string and the compiler
        identification string.

        Note that unlike the Python sys.version, the returned value
        for the Python version will always include the patchlevel (it
        defaults to '.0').

        The function returns empty strings for tuple entries that
        cannot be determined.

        sys_version may be given to parse an alternative version
        string, e.g. if the version was read from a different Python
        interpreter.

    i
t
IronPythons*failed to parse IronPython sys.version: %sRiRtJythons&failed to parse Jython sys.version: %stPyPys$failed to parse PyPy sys.version: %ss'failed to parse CPython sys.version: %stCPythonRt
subversionRiRGN(RKRRt_sys_version_cacheRt_ironpython_sys_version_parserRJRktreprRRt_sys_version_parsert_pypy_sys_version_parserR
RWR+R,RRR(tsys_versiontresultRRJRtalt_versiontcompilerRt	builddatet	buildtimeRtbranchtrevisionRO((s/usr/lib/python2.7/platform.pyt_sys_versionasf		

cCstdS(sR Returns a string identifying the Python implementation.

        Currently, the following implementations are identified:
          'CPython' (C implementation of Python),
          'IronPython' (.NET implementation of Python),
          'Jython' (Java implementation of Python),
          'PyPy' (Python implementation of Python).

    i(Re(((s/usr/lib/python2.7/platform.pytpython_implementationscCstdS(s Returns the Python version as string 'major.minor.patchlevel'

        Note that unlike the Python sys.version, the returned value
        will always include the patchlevel (it defaults to 0).

    i(Re(((s/usr/lib/python2.7/platform.pytpython_versionscCsttjtddS(s Returns the Python version as tuple (major, minor, patchlevel)
        of strings.

        Note that unlike the Python sys.version, the returned value
        will always include the patchlevel (it defaults to 0).

    iR(RLR+R,Re(((s/usr/lib/python2.7/platform.pytpython_version_tuples	cCstdS(s Returns a string identifying the Python implementation
        branch.

        For CPython this is the Subversion branch from which the
        Python binary was built.

        If not available, an empty string is returned.

    i(Re(((s/usr/lib/python2.7/platform.pyt
python_branchscCstdS(s Returns a string identifying the Python implementation
        revision.

        For CPython this is the Subversion revision from which the
        Python binary was built.

        If not available, an empty string is returned.

    i(Re(((s/usr/lib/python2.7/platform.pytpython_revisionscCstdd!S(sh Returns a tuple (buildno, builddate) stating the Python
        build number and date as strings.

    ii(Re(((s/usr/lib/python2.7/platform.pytpython_buildscCstdS(sS Returns a string identifying the compiler used for compiling
        Python.

    i(Re(((s/usr/lib/python2.7/platform.pytpython_compilersic
Cs[tj||fd}|dk	r(|St\}}}}}}||krXd}n|r|t|||\}}}n|dkrt|\}	}
}}|rt||}
qGt||||}
nw|d	krYtd\}}}|r"|r"t||||d|||}
qGtt	j
\}}t||||d||}
n|dkrt\}}}\}}}|s|rt|||}
qGt|||d|||}
n|dkr|rt||}
qGt|||}
nH|rt||}
n0tt	j
\}}t||||||}
|
t||f<|
S(
s Returns a single string identifying the underlying platform
        with as much useful information as possible (but no more :).

        The output is intended to be human readable rather than
        machine parseable. It may look different on different
        platforms and this is intended.

        If "aliased" is true, the function will use aliases for
        various platforms that report system names which differ from
        their common names, e.g. SunOS will be reported as
        Solaris. The system_alias() function is used to implement
        this.

        Setting terse to true causes the function to return only the
        absolute minimum information needed to identify the platform.

    RR	tLinuxtwithREtonRN(Rm(
t_platform_cacheRRKRR
RRRiR"RRRR?(taliasedtterseR^RoRORRRRNtreltversRRRR2tdistversiontdistidtlibcnametlibcversionRRtvRRRRR:R;((s/usr/lib/python2.7/platform.pyRsP	

t__main__Rrs--terset
nonaliaseds--nonaliased(sdosswin32swin16sos2(
sSuSER>R?R@RARBRCRDs	slackwareRERFRGRH((swin32swin16sdossos2(RRR(RRR(RRR(Rs	WindowsPE(RsWindows(RsMSDOS(VRzt
__copyright__t__version__RR+RtretdevnullR&RRtcompileRRR"R=RZRIRMt_supported_distsRPtIRSRURVRhRiRjRKRRRRRRRRRRRRRR
RRR
RRRRRR RR%R)R+R8R,R9R?RJRRoRORRRRNR[RYR\RXReRfRgRhRiRjRkRlRpRxtargvRrRqtexit(((s/usr/lib/python2.7/platform.pyt<module>
sf0

	
3	2		H	6!
	2
		)		#	6	$	
W				
										]	
	
			
		
R