Can't build bazel 7.0.2 from source code on windows
Description of the bug:
Can't build bazel 7.0.2 from source code on windows. How to solve this problem? I have to build bazel 7.0.2 from source code on windows.
MSYS2 shell
cd "C:\src\bazel-7.0.2"
export BAZEL_VS="C:/Program Files (x86)/Microsoft Visual Studio/2017/Professional"
export BAZEL_VC="C:/Program Files (x86)/Microsoft Visual Studio/2017/Professional/VC"
export JAVA_HOME="C:/Program Files (x86)/Java/jdk1.8.0_261"
export PATH="/c/python/python379:$PATH"
C:/bazel/bazel.exe build "src:bazel-dev.exe"
And after a few minutes of normal build process, an error of building external dependencies occurs.
INFO: From Building src/main/java/com/google/devtools/build/lib/profiler/libgoogle-auto-profiler-uti
ls.jar (1 source file):
warning: [options] system modules path not set in conjunction with -source 11
ERROR: C:/msys64/home/Jey/_bazel_Jey/2gt6t7tb/external/grpc~1.48.1.bcr.1/BUILD:3332:16:
Compiling src/core/ext/filters/channel_idle/channel_idle_filter.cc failed: (Exit 2): cl.exe failed:
error executing command (from target @grpc~1.48.1.bcr.1//:grpc_channel_idle_filter) C:\Program Files (x86)\Micr
osoft Visual Studio\2017\Professional\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\cl.exe /nologo /DCOM
PILER_MSVC /DNOMINMAX /D_WIN32_WINNT=0x0601 /D_CRT_SECURE_NO_DEPRECATE ... (remaining 41 arguments s
kipped)
external/grpc~1.48.1.bcr.1/src/core/ext/filters/channel_idle/channel_idle_filter.cc(123): error C224
8: 'grpc_core::ChannelIdleFilter::ChannelIdleFilter': cannot access protected member declared in cla
ss 'grpc_core::ChannelIdleFilter'
C:\msys64\home\Jey\_bazel_Jey\2gt6t7tb\execroot\_main\external\grpc~1.48.1.bcr.1\src/cor
e/ext/filters/channel_idle/channel_idle_filter.h(61): note: see declaration of 'grpc_core::ChannelId
leFilter::ChannelIdleFilter'
C:\msys64\home\Jey\_bazel_Jey\2gt6t7tb\execroot\_main\external\grpc~1.48.1.bcr.1\src/cor
e/ext/filters/channel_idle/channel_idle_filter.h(42): note: see declaration of 'grpc_core::ChannelId
leFilter'
Target //src:bazel-dev.exe failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 350.892s, Critical Path: 60.76s
INFO: 1813 processes: 22 internal, 1548 local, 243 worker.
FAILED: Build did NOT complete successfully
Which category does this issue belong to?
C++ Rules
What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
No response
Which operating system are you running Bazel on?
Windows 10 Pro 22H2 19045.4239
What is the output of bazel info release?
No response
If bazel info release returns development version or (@non-git), tell us how you built Bazel.
No response
What's the output of git remote get-url origin; git rev-parse HEAD ?
No response
Is this a regression? If yes, please try to identify the Bazel commit where the bug was introduced.
No response
Have you found anything relevant by searching the web?
No
Any other information, logs, or outputs that you want to share?
No response
Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 1+ years. It will be closed in the next 90 days unless any other activity occurs. If you think this issue is still relevant and should stay open, please post any comment here and the issue will no longer be marked as stale.
This issue has been automatically closed due to inactivity. If you're still interested in pursuing this, please post @bazelbuild/triage in a comment here and we'll take a look. Thanks!