0
0
mirror of https://github.com/python/cpython.git synced 2024-11-28 08:20:55 +01:00

Tweaked 'get_platform()' to include the first character of the OS release:

eg. sunos5, linux2, irix5.
This commit is contained in:
Greg Ward 2000-03-31 04:40:25 +00:00
parent 7d51034eef
commit 6ce00b4440

View File

@ -545,10 +545,8 @@ def get_platform ():
i.e. "???" or "???"."""
if os.name == 'posix':
uname = os.uname()
OS = uname[0]
arch = uname[4]
return "%s-%s" % (string.lower (OS), string.lower (arch))
(OS, _, rel, _, arch) = os.uname()
return "%s%c-%s" % (string.lower (OS), rel[0], string.lower (arch))
else:
return sys.platform