Closed kschzt closed 3 months ago
I don't have a Windows environment right now to try it out. Do you get the same error when building just https://github.com/buildbarn/go-xdr?
@moroten No errors building that with bazel build //cmd/xdr_compiler
.
PS. FYI I'm setting up a Windows RBE cluster for building Chromium with goma (natively), and buildbarn is the best on Linux (4 machines, 256 cores) – I tried all the OS RBE solutions – so I'd love to get this to work on Windows! 😊
You’re seeing this error, because it reran Gazelle in the go-xdr repo, which causes it to also build the generated source files.
@EdSchouten thanks. I'm pretty new to bazel. How can I tell it not to do that? And what makes it (only) do that on Windows? Thanks again!
Using bazel 5.3.1 btw.
I've worked around this by building the rbe and storage repos separately - they build just fine.
Good to hear that it works for you. I'll keep this ticket open to see if I can have a look at it in a few months time.
FYI I then failed at Failed to create Content Addressable Storage: rpc error: code = Unimplemented desc = Failed to open blocks block device: Memory mapping block devices is not supported on this platform
which is another thing entirely :)
@EdSchouten thanks. I'm pretty new to bazel. How can I tell it not to do that? And what makes it (only) do that on Windows? Thanks again!
In go_dependencies.bzl you will find something like this:
go_repository(
name = "com_github_buildbarn_go_xdr",
importpath = "github.com/buildbarn/go-xdr",
sum = "h1:aVYAcBUakcn8QvCdKroXmjGjQBBqv3FLftTyiHjgKAQ=",
version = "v0.0.0-20220804060714-a6fffae29b77",
)
You could try adding build_file_generation = "off",
to that. That will force it to use the BUILD files that are already in the repository.
Hi, the build fails with duplicate declarations as below. Running in Windows 11 Pro in a Git Bash (as the build requires bash for patching). Any clues as to how to fix?