I'm not sure how Mercurial is relevant. From reading the Buck2 getting started docs, it looks like it works just fine with Git repos.
Buck2 notably though tries to be a good persistent incremental build system, and it needs much more awareness of things changing. It does integrate with Sapling for these kind of reasons.
So the boundaries are a bit blurrier than they used to be between scm/build/ci/CD tools.