Our great sponsors
The central registry of Bazel modules for the Bzlmod external dependency system.
The main change here is that Bazel now has a package repository that people can pull/push external dependencies to: https://registry.bazel.build/
This is a huge change as external dependencies used to be one of the big pain points with the Bazel pipeline.
a fast, scalable, multi-language and extensible build system
None, bazel's caching implementation is broken because they don't even know or specify what constituents a build a build hash/key. See this issue from 2018 that's still open .
Clean code begins in your IDE with SonarLint. Up your coding game and discover issues early. SonarLint is a free plugin that helps you find & fix bugs and security issues from the moment you start writing code. Install from your favorite IDE marketplace today.
I don't know what you're talking about. This is trivial to accomplish using `linkstatic` as documented on `cc_library` and `cc_binary`. I uploaded a demo to github here: https://github.com/emidln/bazel_static_dynamic_c_demo/blob/m...
Try it out like this:
# you'll need a c compiler installed, xcode is fine on macos
C++ Rules for Bazel
Not that I'd recommend it, but if you symlink your system library into the bazel build area, as long as your sandboxing setup don't hose you (or you just turn it off), bazel will track system tools/library in the same way as everything else.
Bazel's rules_cc even has a system_library.bzl you can import a `system_library` from that automates this for you. https://github.com/bazelbuild/rules_cc/blob/main/cc/system_l...
I'd still recommend building everything from scratch (and understanding the relationships and graph of your dependencies), but if your build isn't that complicated and you want to role the dice on UB, this isn't that hard.
As an aside, the most galling part of bazel's cache key calculations has to be that it's up to the individual rules to implement this how they see fit. The rules native to bazel written in java vary wildly compared to starlark-written rules. On thing you (or someone in your org) end up becoming pretty comfortable with while using bazel in anger is RTFC.
Dependency tracker for (really big) builds / deploys
2 projects | reddit.com/r/devops | 21 Mar 2023
Slow tab completion on zsh
1 project | reddit.com/r/bazel | 11 Mar 2023
How to make distributable binaries in bazel?
2 projects | reddit.com/r/bazel | 21 Feb 2023
How To Run This Script?
3 projects | reddit.com/r/Gentoo | 17 Feb 2023
Using variables in Bazel
1 project | dev.to | 16 Feb 2023