Move tflite http_archive and http_file WORKSPACE http_archive rules into tensorflow/workspace.bzl, where the rest of the external dependency configuration lives. This change also converts these rules into tf_http_archive, and adds appropriate mirrors.
PiperOrigin-RevId: 289569601 Change-Id: I6d9382a5f61e9a53f627efd632097062c17b9a79
This commit is contained in:
parent
e7af6b1c2e
commit
8782b7679c
34
WORKSPACE
34
WORKSPACE
@ -1,6 +1,6 @@
|
||||
workspace(name = "org_tensorflow")
|
||||
|
||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive", "http_file")
|
||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||
|
||||
http_archive(
|
||||
name = "io_bazel_rules_closure",
|
||||
@ -48,38 +48,6 @@ load("//third_party/toolchains/preconfig/generate:workspace.bzl",
|
||||
|
||||
remote_config_workspace()
|
||||
|
||||
# Apple and Swift rules.
|
||||
http_archive(
|
||||
name = "build_bazel_rules_apple",
|
||||
sha256 = "a045a436b642c70fb0c10ca84ff0fd2dcbd59cc89100d597a61e8374afafb366",
|
||||
urls = ["https://github.com/bazelbuild/rules_apple/releases/download/0.18.0/rules_apple.0.18.0.tar.gz"],
|
||||
) # https://github.com/bazelbuild/rules_apple/releases
|
||||
http_archive(
|
||||
name = "build_bazel_rules_swift",
|
||||
sha256 = "18cd4df4e410b0439a4935f9ca035bd979993d42372ba79e7f2d4fafe9596ef0",
|
||||
urls = ["https://github.com/bazelbuild/rules_swift/releases/download/0.12.1/rules_swift.0.12.1.tar.gz"],
|
||||
) # https://github.com/bazelbuild/rules_swift/releases
|
||||
http_archive(
|
||||
name = "build_bazel_apple_support",
|
||||
sha256 = "122ebf7fe7d1c8e938af6aeaee0efe788a3a2449ece5a8d6a428cb18d6f88033",
|
||||
urls = ["https://github.com/bazelbuild/apple_support/releases/download/0.7.1/apple_support.0.7.1.tar.gz"],
|
||||
) # https://github.com/bazelbuild/apple_support/releases
|
||||
http_archive(
|
||||
name = "bazel_skylib",
|
||||
sha256 = "1dde365491125a3db70731e25658dfdd3bc5dbdfd11b840b3e987ecf043c7ca0",
|
||||
urls = ["https://github.com/bazelbuild/bazel-skylib/releases/download/0.9.0/bazel-skylib.0.9.0.tar.gz"],
|
||||
) # https://github.com/bazelbuild/bazel-skylib/releases
|
||||
http_archive(
|
||||
name = "com_github_apple_swift_swift_protobuf",
|
||||
type = "zip",
|
||||
strip_prefix = "swift-protobuf-1.6.0/",
|
||||
urls = ["https://github.com/apple/swift-protobuf/archive/1.6.0.zip"],
|
||||
) # https://github.com/apple/swift-protobuf/releases
|
||||
http_file(
|
||||
name = "xctestrunner",
|
||||
executable = 1,
|
||||
urls = ["https://github.com/google/xctestrunner/releases/download/0.2.9/ios_test_runner.par"],
|
||||
) # https://github.com/google/xctestrunner/releases
|
||||
# Use `swift_rules_dependencies` to fetch the toolchains. With the
|
||||
# `git_repository` rules above, the following call will skip redefining them.
|
||||
load("@build_bazel_rules_swift//swift:repositories.bzl", "swift_rules_dependencies")
|
||||
|
@ -14,6 +14,7 @@ load("//third_party/toolchains/clang6:repo.bzl", "clang6_configure")
|
||||
load("//third_party/toolchains/cpus/arm:arm_compiler_configure.bzl", "arm_compiler_configure")
|
||||
load("//third_party:repo.bzl", "tf_http_archive")
|
||||
load("//third_party/clang_toolchain:cc_configure_clang.bzl", "cc_download_clang_toolchain")
|
||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_file")
|
||||
load("@bazel_tools//tools/build_defs/repo:java.bzl", "java_import_external")
|
||||
load("@io_bazel_rules_closure//closure:defs.bzl", "filegroup_external")
|
||||
load(
|
||||
@ -888,6 +889,68 @@ def tf_repositories(path_prefix = "", tf_repo_name = ""):
|
||||
],
|
||||
)
|
||||
|
||||
# Apple and Swift rules.
|
||||
# https://github.com/bazelbuild/rules_apple/releases
|
||||
tf_http_archive(
|
||||
name = "build_bazel_rules_apple",
|
||||
sha256 = "a045a436b642c70fb0c10ca84ff0fd2dcbd59cc89100d597a61e8374afafb366",
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/bazelbuild/rules_apple/releases/download/0.18.0/rules_apple.0.18.0.tar.gz",
|
||||
"https://github.com/bazelbuild/rules_apple/releases/download/0.18.0/rules_apple.0.18.0.tar.gz",
|
||||
],
|
||||
)
|
||||
|
||||
# https://github.com/bazelbuild/rules_swift/releases
|
||||
tf_http_archive(
|
||||
name = "build_bazel_rules_swift",
|
||||
sha256 = "18cd4df4e410b0439a4935f9ca035bd979993d42372ba79e7f2d4fafe9596ef0",
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/bazelbuild/rules_swift/releases/download/0.12.1/rules_swift.0.12.1.tar.gz",
|
||||
"https://github.com/bazelbuild/rules_swift/releases/download/0.12.1/rules_swift.0.12.1.tar.gz",
|
||||
],
|
||||
)
|
||||
|
||||
# https://github.com/bazelbuild/apple_support/releases
|
||||
tf_http_archive(
|
||||
name = "build_bazel_apple_support",
|
||||
sha256 = "122ebf7fe7d1c8e938af6aeaee0efe788a3a2449ece5a8d6a428cb18d6f88033",
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/bazelbuild/apple_support/releases/download/0.7.1/apple_support.0.7.1.tar.gz",
|
||||
"https://github.com/bazelbuild/apple_support/releases/download/0.7.1/apple_support.0.7.1.tar.gz",
|
||||
],
|
||||
)
|
||||
|
||||
# https://github.com/bazelbuild/bazel-skylib/releases
|
||||
tf_http_archive(
|
||||
name = "bazel_skylib",
|
||||
sha256 = "1dde365491125a3db70731e25658dfdd3bc5dbdfd11b840b3e987ecf043c7ca0",
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/bazelbuild/bazel-skylib/releases/download/0.9.0/bazel_skylib-0.9.0.tar.gz",
|
||||
"https://github.com/bazelbuild/bazel-skylib/releases/download/0.9.0/bazel_skylib-0.9.0.tar.gz",
|
||||
],
|
||||
)
|
||||
|
||||
# https://github.com/apple/swift-protobuf/releases
|
||||
tf_http_archive(
|
||||
name = "com_github_apple_swift_swift_protobuf",
|
||||
strip_prefix = "swift-protobuf-1.6.0/",
|
||||
sha256 = "4ccf6e5ea558e8287bf6331f9f6e52b3c321fca5f1d181d03680f415c32a6bba",
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/apple/swift-protobuf/archive/1.6.0.zip",
|
||||
"https://github.com/apple/swift-protobuf/archive/1.6.0.zip",
|
||||
],
|
||||
)
|
||||
|
||||
# https://github.com/google/xctestrunner/releases
|
||||
http_file(
|
||||
name = "xctestrunner",
|
||||
executable = 1,
|
||||
urls = [
|
||||
"http://mirror.tensorflow.org/github.com/google/xctestrunner/releases/download/0.2.9/ios_test_runner.par",
|
||||
"https://github.com/google/xctestrunner/releases/download/0.2.9/ios_test_runner.par",
|
||||
],
|
||||
)
|
||||
|
||||
tf_http_archive(
|
||||
name = "tbb",
|
||||
build_file = clean_dep("//third_party/ngraph:tbb.BUILD"),
|
||||
|
Loading…
Reference in New Issue
Block a user