Skip to content

Commit

Permalink
Merge pull request #227 from comius:upgrade-rules_cc
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 693742825
  • Loading branch information
Blaze Rules Copybara committed Nov 6, 2024
2 parents 1bcd191 + 44afe3e commit 8f6551b
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 19 deletions.
5 changes: 3 additions & 2 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ module(

bazel_dep(name = "protobuf", version = "27.1", repo_name = "com_google_protobuf")
bazel_dep(name = "bazel_skylib", version = "1.3.0")
bazel_dep(name = "rules_cc", version = "0.0.1")
bazel_dep(name = "rules_cc", version = "0.0.14")
bazel_dep(name = "rules_license", version = "0.0.7")

# Dependencies needed in tests
bazel_dep(name = "stardoc", version = "0.7.1", dev_dependency = True, repo_name = "io_bazel_stardoc")
bazel_dep(name = "googletest", version = "1.11.0", dev_dependency = True, repo_name = "com_google_googletest")
bazel_dep(name = "rules_shell", version = "0.2.0", dev_dependency = True) # only used in docs
bazel_dep(name = "platforms", version = "0.0.8", dev_dependency = True)
bazel_dep(name = "googletest", version = "1.11.0", dev_dependency = True, repo_name = "com_google_googletest")
12 changes: 8 additions & 4 deletions MODULE.bazel.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions dev_deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,13 @@ def rules_proto_dev_deps():
],
)

http_archive(
name = "rules_shell",
sha256 = "410e8ff32e018b9efd2743507e7595c26e2628567c42224411ff533b57d27c28",
strip_prefix = "rules_shell-0.2.0",
url = "https://github.com/bazelbuild/rules_shell/releases/download/v0.2.0/rules_shell-v0.2.0.tar.gz",
)

http_archive(
name = "com_google_googletest",
sha256 = "81964fe578e9bd7c94dfdb09c8e4d6e6759e19967e397dbea48d1c10e45d0df2",
Expand Down
4 changes: 2 additions & 2 deletions docs/stardoc_with_diff_test.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

"""Helpers for keeping stardoc documentation up-to-date.
These are currently a private API in bazel-skylib.
Expand All @@ -26,6 +25,7 @@ https://github.com/aspect-build/bazel-lib/blob/main/docs/docs.md
load("@bazel_skylib//rules:diff_test.bzl", "diff_test")
load("@bazel_skylib//rules:write_file.bzl", "write_file")
load("@io_bazel_stardoc//stardoc:stardoc.bzl", "stardoc")
load("@rules_shell//shell:sh_binary.bzl", "sh_binary")

def stardoc_with_diff_test(
name,
Expand Down Expand Up @@ -104,7 +104,7 @@ def update_docs(
content = content,
)

native.sh_binary(
sh_binary(
name = name,
srcs = [update_script],
data = data,
Expand Down
29 changes: 18 additions & 11 deletions proto/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,10 @@ def rules_proto_dependencies():
maybe(
http_archive,
name = "bazel_skylib",
sha256 = "74d544d96f4a5bb630d465ca8bbcfe231e3594e5aae57e1edbf17a6eb3ca2506",
sha256 = "d00f1389ee20b60018e92644e0948e16e350a7707219e7a390fb0a99b6ec9262",
urls = [
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.3.0/bazel-skylib-1.3.0.tar.gz",
"https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.7.0/bazel-skylib-1.7.0.tar.gz",
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.7.0/bazel-skylib-1.7.0.tar.gz",
],
)
maybe(
Expand All @@ -51,18 +52,24 @@ def rules_proto_dependencies():
maybe(
http_archive,
name = "rules_cc",
sha256 = "4aeb102efbcfad509857d7cb9c5456731e8ce566bfbf2960286a2ec236796cc3",
strip_prefix = "rules_cc-2f8c04c04462ab83c545ab14c0da68c3b4c96191",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_cc/archive/2f8c04c04462ab83c545ab14c0da68c3b4c96191.tar.gz",
"https://github.com/bazelbuild/rules_cc/archive/2f8c04c04462ab83c545ab14c0da68c3b4c96191.tar.gz",
],
urls = ["https://github.com/bazelbuild/rules_cc/releases/download/0.0.14/rules_cc-0.0.14.tar.gz"],
sha256 = "906e89286acc67c20819c3c88b3283de0d5868afda33635d70acae0de9777bb7",
strip_prefix = "rules_cc-0.0.14",
)

maybe(
http_archive,
name = "rules_python",
sha256 = "d70cd72a7a4880f0000a6346253414825c19cdd40a28289bdf67b8e6480edff8",
strip_prefix = "rules_python-0.28.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.28.0/rules_python-0.28.0.tar.gz",
sha256 = "ca77768989a7f311186a29747e3e95c936a41dffac779aff6b443db22290d913",
strip_prefix = "rules_python-0.36.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.36.0/rules_python-0.36.0.tar.gz",
)

maybe(
http_archive,
name = "rules_java",
urls = [
"https://github.com/bazelbuild/rules_java/releases/download/8.3.0/rules_java-8.3.0.tar.gz",
],
sha256 = "c7bd858a132c7b8febe040a90fa138c2e3e7f0bce47122ac2ad43906036a276c",
)

0 comments on commit 8f6551b

Please sign in to comment.