mirror of
https://github.com/vale981/ray
synced 2025-03-06 10:31:39 -05:00
parent
02cbd4fb7e
commit
3d0a3c47a8
1 changed files with 7 additions and 2 deletions
|
@ -178,8 +178,13 @@ def build(build_python, build_java):
|
|||
"Detected: {}\n at: {!r}".format(sys.version, sys.executable))
|
||||
raise OSError(msg)
|
||||
|
||||
bazel_env = dict(os.environ, PYTHON3_BIN_PATH=sys.executable)
|
||||
|
||||
if is_native_windows_or_msys():
|
||||
BAZEL_SH = os.getenv("BAZEL_SH")
|
||||
SHELL = bazel_env.get("SHELL")
|
||||
if SHELL:
|
||||
bazel_env.setdefault("BAZEL_SH", os.path.normpath(SHELL))
|
||||
BAZEL_SH = bazel_env["BAZEL_SH"]
|
||||
SYSTEMROOT = os.getenv("SystemRoot")
|
||||
wsl_bash = os.path.join(SYSTEMROOT, "System32", "bash.exe")
|
||||
if (not BAZEL_SH) and SYSTEMROOT and os.path.isfile(wsl_bash):
|
||||
|
@ -222,7 +227,7 @@ def build(build_python, build_java):
|
|||
bazel_targets += ["//java:ray_java_pkg"] if build_java else []
|
||||
return subprocess.check_call(
|
||||
[bazel, "build", "--verbose_failures", "--"] + bazel_targets,
|
||||
env=dict(os.environ, PYTHON3_BIN_PATH=sys.executable))
|
||||
env=bazel_env)
|
||||
|
||||
|
||||
def walk_directory(directory):
|
||||
|
|
Loading…
Add table
Reference in a new issue