use 'new_git_repository' in external deps call to work with older bazel versions

This commit is contained in:
Dominic Hamon 2023-03-16 09:49:12 +00:00
parent efc89f0b52
commit 0c34d812e4
1 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,5 @@
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
load("@bazel_tools//tools/build_defs/repo:git.bzl", "new_git_repository")
def benchmark_deps():
"""Loads dependencies required to build Google Benchmark."""
@ -38,14 +38,14 @@ def benchmark_deps():
)
if "com_google_googletest" not in native.existing_rules():
git_repository(
new_git_repository(
name = "com_google_googletest",
remote = "https://github.com/google/googletest.git",
tag = "release-1.11.0",
)
if "nanobind" not in native.existing_rules():
git_repository(
new_git_repository(
name = "nanobind",
remote = "https://github.com/wjakob/nanobind.git",
commit = "1ffbfe836c9dac599496a170274ee0075094a607", # v0.2.0