blob: 3641b3bdad1d3922b853e553b70fc08b6a22da3c [file] [log] [blame]
# Copyright 2022 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
BAZEL_SDK_SHA256 = "7d0d418b20f33bb741f4b70966673ed97cf22b1a4bae809380836107a724d3cb"
BAZEL_SDK_URL = "https://chrome-infra-packages.appspot.com/dl/fuchsia/sdk/core/fuchsia-bazel-rules/linux-amd64/+/version:11.20230207.2.1"
# TODO(https://fxbug.dev/120912): Migrate off of @rules_fuchsia.
http_archive(
name = "rules_fuchsia",
sha256 = BAZEL_SDK_SHA256,
type = "zip",
url = BAZEL_SDK_URL,
)
# TODO(https://fxbug.dev/120912): Switch to the git submodule once available.
http_archive(
name = "fuchsia_sdk",
sha256 = BAZEL_SDK_SHA256,
type = "zip",
url = BAZEL_SDK_URL,
)
local_repository(
name = "fuchsia_infra",
path = "third_party/fuchsia-infra-bazel-rules",
)
load("@fuchsia_infra//:workspace.bzl", "fuchsia_infra_workspace")
fuchsia_infra_workspace()
load(
"@rules_fuchsia//fuchsia:deps.bzl",
"fuchsia_clang_repository",
"rules_fuchsia_deps",
)
rules_fuchsia_deps()
register_toolchains("@fuchsia_sdk//:fuchsia_toolchain_sdk")
fuchsia_clang_repository(
name = "fuchsia_clang",
sdk_root_label = "@fuchsia_sdk",
)
load("@fuchsia_clang//:defs.bzl", "register_clang_toolchains")
register_clang_toolchains()
# gTest.
local_repository(
name = "com_google_googletest",
path = "third_party/googletest",
)
http_archive(
name = "bazel_skylib",
sha256 = "f7be3474d42aae265405a592bb7da8e171919d74c16f082a5457840f06054728",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.2.1/bazel-skylib-1.2.1.tar.gz",
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.2.1/bazel-skylib-1.2.1.tar.gz",
],
)
load("@bazel_skylib//:workspace.bzl", "bazel_skylib_workspace")
bazel_skylib_workspace()