@@ -611,17 +611,9 @@ def wrap(func):
611611 def wrapper (* args , ** kwargs ):
612612 if sys .platform != "linux" :
613613 return func (* args , ** kwargs )
614- if not hasattr (install_cargo_config , "tmpdir" ) and os .environ .get (
615- "RELENV_BUILDENV" , 0
616- ):
617- raise RuntimeError ("No toolchain installed" )
614+ base_dir = common ().DATA_DIR / "toolchain"
615+ toolchain = base_dir / common ().get_triplet ()
618616 cargo_home = install_cargo_config .tmpdir .name
619- toolchain = common ().get_toolchain ()
620- if not toolchain :
621- if os .environ .get ("RELENV_BUILDENV" , 0 ):
622- raise RuntimeError ("No toolchain installed" )
623- return func (* args , ** kwargs )
624-
625617 if not toolchain .exists ():
626618 debug ("Unable to set CARGO_HOME no toolchain exists" )
627619 else :
@@ -1083,11 +1075,3 @@ def bootstrap():
10831075 setup_crossroot ()
10841076 install_cargo_config ()
10851077 sys .meta_path = [importer ] + sys .meta_path
1086- # XXX This causes our m2crypto test to break
1087- # if "RELENV_BUILDENV" in os.environ:
1088- # env = buildenv().buildenv()
1089- # for key in env:
1090- # if key in os.environ:
1091- # os.environ[key] = f"{env[key]} {os.environ[key]}"
1092- # else:
1093- # os.environ[key] = env[key]
0 commit comments