Remove Bazel WORKSPACE setup. (#8509)

This commit is contained in:
Marcel
2025-01-24 19:16:10 +01:00
committed by GitHub
parent 65e49faf76
commit 82fefbf252
12 changed files with 2 additions and 324 deletions

View File

@@ -7,19 +7,13 @@ Rules for building C++ flatbuffers with Bazel.
load("@rules_cc//cc:defs.bzl", "cc_library")
def repo_name(label):
if hasattr(label, "repo_name"): # Added in Bazel 7.1
return label.repo_name
else:
return "com_github_google_flatbuffers"
TRUE_FLATC_PATH = Label("//:flatc")
DEFAULT_INCLUDE_PATHS = [
"./",
"$(GENDIR)",
"$(BINDIR)",
"$(execpath %s).runfiles/%s" % (TRUE_FLATC_PATH, repo_name(TRUE_FLATC_PATH)),
"$(execpath %s).runfiles/%s" % (TRUE_FLATC_PATH, TRUE_FLATC_PATH.repo_name),
]
def default_include_paths(flatc_path):
@@ -27,7 +21,7 @@ def default_include_paths(flatc_path):
"./",
"$(GENDIR)",
"$(BINDIR)",
"$(execpath %s).runfiles/%s" % (flatc_path, repo_name(flatc_path)),
"$(execpath %s).runfiles/%s" % (flatc_path, flatc_path.repo_name),
]
DEFAULT_FLATC_ARGS = [