From ac7e3e636facb5502ff9b96634651367f71a777a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?X=C3=B9d=C5=8Dng=20Y=C3=A1ng?= Date: Fri, 23 Aug 2024 16:29:49 -0400 Subject: [PATCH] Update C++ tutorial to use Bzlmod (#486) - Renamed WORKSPACE to MODULE.bazel - removed `load`s from `rules_cc` in BUILD files, as that's still in flux. --- cpp-tutorial/stage1/{WORKSPACE => MODULE.bazel} | 0 cpp-tutorial/stage1/main/BUILD | 2 -- cpp-tutorial/stage2/{WORKSPACE => MODULE.bazel} | 0 cpp-tutorial/stage2/main/BUILD | 2 -- cpp-tutorial/stage3/{WORKSPACE => MODULE.bazel} | 0 cpp-tutorial/stage3/lib/BUILD | 2 -- cpp-tutorial/stage3/main/BUILD | 2 -- 7 files changed, 8 deletions(-) rename cpp-tutorial/stage1/{WORKSPACE => MODULE.bazel} (100%) rename cpp-tutorial/stage2/{WORKSPACE => MODULE.bazel} (100%) rename cpp-tutorial/stage3/{WORKSPACE => MODULE.bazel} (100%) diff --git a/cpp-tutorial/stage1/WORKSPACE b/cpp-tutorial/stage1/MODULE.bazel similarity index 100% rename from cpp-tutorial/stage1/WORKSPACE rename to cpp-tutorial/stage1/MODULE.bazel diff --git a/cpp-tutorial/stage1/main/BUILD b/cpp-tutorial/stage1/main/BUILD index dd1db644f..20c6f473b 100644 --- a/cpp-tutorial/stage1/main/BUILD +++ b/cpp-tutorial/stage1/main/BUILD @@ -1,5 +1,3 @@ -load("@rules_cc//cc:defs.bzl", "cc_binary") - cc_binary( name = "hello-world", srcs = ["hello-world.cc"], diff --git a/cpp-tutorial/stage2/WORKSPACE b/cpp-tutorial/stage2/MODULE.bazel similarity index 100% rename from cpp-tutorial/stage2/WORKSPACE rename to cpp-tutorial/stage2/MODULE.bazel diff --git a/cpp-tutorial/stage2/main/BUILD b/cpp-tutorial/stage2/main/BUILD index 3d0ba0403..43b22a425 100644 --- a/cpp-tutorial/stage2/main/BUILD +++ b/cpp-tutorial/stage2/main/BUILD @@ -1,5 +1,3 @@ -load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library") - cc_library( name = "hello-greet", srcs = ["hello-greet.cc"], diff --git a/cpp-tutorial/stage3/WORKSPACE b/cpp-tutorial/stage3/MODULE.bazel similarity index 100% rename from cpp-tutorial/stage3/WORKSPACE rename to cpp-tutorial/stage3/MODULE.bazel diff --git a/cpp-tutorial/stage3/lib/BUILD b/cpp-tutorial/stage3/lib/BUILD index e5416817a..a2ab4e66a 100644 --- a/cpp-tutorial/stage3/lib/BUILD +++ b/cpp-tutorial/stage3/lib/BUILD @@ -1,5 +1,3 @@ -load("@rules_cc//cc:defs.bzl", "cc_library") - cc_library( name = "hello-time", srcs = ["hello-time.cc"], diff --git a/cpp-tutorial/stage3/main/BUILD b/cpp-tutorial/stage3/main/BUILD index e4108f08a..6242dcd15 100644 --- a/cpp-tutorial/stage3/main/BUILD +++ b/cpp-tutorial/stage3/main/BUILD @@ -1,5 +1,3 @@ -load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library") - cc_library( name = "hello-greet", srcs = ["hello-greet.cc"],