blob: 4e68665418d10c19e31877c5e11832a864f42aa9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
import platform
import sys
def get_uname():
return " ".join(platform.uname())
def get_kernel_version():
return get_uname().split()[2]
def get_hostname():
return platform.uname().node
def get_cc_version():
with open("build/ccinfo", "r") as ccinfo:
return ccinfo.readlines()[-1][:-1]
def get_libc_version(bin=None):
bin = bin or sys.executable
platform.libc_ver(executable=bin)
|