Skip to content

Commit

Permalink
Tweaked 'get_platform()' to include the first character of the OS rel…
Browse files Browse the repository at this point in the history
…ease:

eg. sunos5, linux2, irix5.
  • Loading branch information
gward committed Mar 31, 2000
1 parent 7d51034 commit 6ce00b4
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions Lib/distutils/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down

0 comments on commit 6ce00b4

Please sign in to comment.