mirror of https://github.com/Jittor/Jittor
updated polish
This commit is contained in:
parent
3fdda2f91d
commit
582bdfe52b
|
@ -1041,7 +1041,7 @@ if platform.system() == 'Linux':
|
|||
if len(a) != 2: continue
|
||||
os_release[a[0]] = a[1].replace("\"", "")
|
||||
elif platform.system() == 'Darwin':
|
||||
os_release = {'ID' : 'macOS'}
|
||||
os_release = {'ID' : 'macos'}
|
||||
|
||||
os_type = {
|
||||
"ubuntu": "ubuntu",
|
||||
|
@ -1049,7 +1049,7 @@ os_type = {
|
|||
"centos": "centos",
|
||||
"rhel": "ubuntu",
|
||||
"fedora": "ubuntu",
|
||||
"macOS": "macOS",
|
||||
"macos": "macos",
|
||||
}
|
||||
|
||||
version_file = os.path.join(jittor_path, "version")
|
||||
|
|
|
@ -23,6 +23,7 @@ from jittor.compiler import run_cmd
|
|||
from jittor_utils import translator
|
||||
from jittor.utils.polish_centos import run_in_centos
|
||||
import sys
|
||||
import platform
|
||||
|
||||
jittor_path = jt.flags.jittor_path
|
||||
root_path = os.path.realpath(os.path.join(jt.flags.jittor_path, "..", ".."))
|
||||
|
@ -52,7 +53,17 @@ from pathlib import Path
|
|||
home = str(Path.home())
|
||||
# for cc_type in ["g++", "clang"]:
|
||||
# for device in ["cpu", "cuda"]:
|
||||
for os_name in ['ubuntu', 'centos']:
|
||||
|
||||
os_name_system_dict = {
|
||||
'ubuntu': 'Linux',
|
||||
'centos': 'Linux',
|
||||
'macos': 'Darwin',
|
||||
}
|
||||
|
||||
for os_name, os_type in os_name_system_dict.items():
|
||||
if platform.system() != os_type:
|
||||
continue
|
||||
|
||||
for cc_type in ["g++"]:
|
||||
for device in ["cpu"]:
|
||||
key = f"{git_version}-{cc_type}-{device}"
|
||||
|
|
Loading…
Reference in New Issue