[PATCH] D143344: [bazel] Port zstd support

Aaron Siddhartha Mondal via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 28 15:08:52 PDT 2023


aaronmondal added inline comments.


================
Comment at: utils/bazel/WORKSPACE:126
+maybe(
+    http_archive,
+    name = "llvm_zstd",
----------------
GMNGeoffrey wrote:
> Can we use `new_git_repository` here instead?
This was because of the hash failure for archives with github right? I'm not sure whether `new_git_repository` is a good idea here since we are using a stable archive (which AFAIK is guaranteed to be hash-stable). At least according to the bazel docs 

> Prefer http_archive to git_repository. The reasons are:

  - Git repository rules depend on system git(1) whereas the HTTP downloader is built into Bazel and has no system dependencies.
  - http_archive supports a list of urls as mirrors, and git_repository supports only a single remote.
  - http_archive works with the repository cache, but not git_repository. See #5116 for more information.

I'm only really worried about the third point here. You know the best practices better though, so I'm happy to change this if you prefer `new_git_repository`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D143344/new/

https://reviews.llvm.org/D143344



More information about the llvm-commits mailing list