-
Notifications
You must be signed in to change notification settings - Fork 58
/
Copy path.bazelrc
91 lines (82 loc) · 3.98 KB
/
.bazelrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# bazel configurations for tensorboard plugin build.
build:linux --repo_env=CC="/usr/bin/clang"
build --repo_env=TF_PYTHON_VERSION=3.10
build --experimental_repo_remote_exec
build --cxxopt=-std=c++17
build --host_cxxopt=-std=c++17
build --copt=-Wno-gnu-offsetof-extensions
build --copt=-Wno-error=array-parameter
build --copt=-Wno-error=unused-command-line-argument
build --copt=-w
build:macos --apple_platform_type=macos
build:macos --copt=-DGRPC_BAZEL_BUILD
build:windows --compiler=clang-cl
build:windows --copt=/W0
build:windows --host_copt=/W0
build:windows --copt=/Zc:__cplusplus
build:windows --host_copt=/Zc:__cplusplus
build:windows --copt=/D_USE_MATH_DEFINES
build:windows --host_copt=/D_USE_MATH_DEFINES
build:windows --features=compiler_param_file
build:windows --features=archive_param_file
build:windows --cxxopt=/std:c++17
build:windows --host_cxxopt=/std:c++17
build:windows --copt=-DWIN32_LEAN_AND_MEAN
build:windows --host_copt=-DWIN32_LEAN_AND_MEAN
build:windows --copt=-DNOGDI
build:windows --host_copt=-DNOGDI
build:windows --linkopt=/DEBUG
build:windows --host_linkopt=/DEBUG
build:windows --linkopt=/OPT:REF
build:windows --host_linkopt=/OPT:REF
build:windows --linkopt=/OPT:ICF
build:windows --host_linkopt=/OPT:ICF
# #############################################################################
# RBE config options below. These inherit the CI configs above and set the
# remote execution backend and authentication options required to run builds
# with RBE. Linux x86 and Windows builds use RBE.
# Based off of https://github.com/tensorflow/tensorflow/blob/master/.bazelrc
# #############################################################################
# Allow creation of resultstore URLs for any bazel invocation
build:resultstore --google_default_credentials
build:resultstore --bes_backend=buildeventservice.googleapis.com
build:resultstore --bes_instance_name="tensorflow-testing"
build:resultstore --bes_results_url="https://source.cloud.google.com/results/invocations"
build:resultstore --bes_timeout=600s
build:avx_linux --copt=-mavx
build:avx_linux --host_copt=-mavx
# Flag to enable remote config
common --experimental_repo_remote_exec
# Make Bazel not try to probe the host system for a C++ toolchain.
build:rbe_base --config=resultstore
build:rbe_base --repo_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1
build:rbe_base --define=EXECUTOR=remote
build:rbe_base --jobs=800
build:rbe_base --remote_executor=grpcs://remotebuildexecution.googleapis.com
build:rbe_base --remote_timeout=3600
build:rbe_base --spawn_strategy=remote,worker,standalone,local
# Attempt to minimize the amount of data transfer between bazel and the remote
# workers:
build:rbe_base --remote_download_toplevel
test:rbe_base --test_env=USER=anon
build:rbe_linux --config=rbe_base
build:rbe_linux --action_env=PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin"
# Non-rbe settings we should include because we do not run configure
build:rbe_linux --config=avx_linux
build:rbe_linux --linkopt=-lrt
build:rbe_linux --host_linkopt=-lrt
build:rbe_linux --linkopt=-lm
build:rbe_linux --host_linkopt=-lm
build:rbe_linux_cpu --config=rbe_linux
# Linux cpu and cuda builds share the same toolchain now.
build:rbe_linux_cpu --host_crosstool_top="@local_config_cuda//crosstool:toolchain"
build:rbe_linux_cpu --crosstool_top="@local_config_cuda//crosstool:toolchain"
build:rbe_linux_cpu --extra_toolchains="@local_config_cuda//crosstool:toolchain-linux-x86_64"
build:rbe_linux_cpu --repo_env=CC="/usr/lib/llvm-18/bin/clang"
build:rbe_linux_cpu --repo_env=TF_SYSROOT="/dt9"
build:rbe_linux_cpu --extra_execution_platforms="@ml_build_config_platform//:platform"
build:rbe_linux_cpu --host_platform="@ml_build_config_platform//:platform"
build:rbe_linux_cpu --platforms="@ml_build_config_platform//:platform"
# Python config is the same across all containers because the binary is the same
build:rbe_linux_cpu --python_path="/usr/bin/python3"
common:rbe_linux_cpu --remote_instance_name=projects/tensorflow-testing/instances/default_instance