aboutsummaryrefslogtreecommitdiffhomepage
path: root/WORKSPACE
diff options
context:
space:
mode:
authorGravatar josh <jwpowell055@gmail.com>2017-10-18 22:00:26 -0600
committerGravatar josh <jwpowell055@gmail.com>2017-10-19 18:47:58 -0600
commit5d710a5dfe7110c73e5f755e842b1b2360969875 (patch)
tree2022c5cd0153938ff46475dd64ee0dd590b738a4 /WORKSPACE
parent4b8e4756426da3056fab06fd358ebc211cb7b8c6 (diff)
Update Bazel WORKSPACE file and third_party/cares BUILD files to that Bazel can build gRPC as a dependency.
The WORKSPACE file now pulls third_party dependencies directly instead of requiring a git submodule init and update. The git hashes pulled by Bazel are exactly the same as the git submodules checked into third_party. A tiny bit of complexity comes from the c-ares project's use of ares_config.h.cmake and ares_build.c.cmake. The current solution to this problem is to check in a valid ares_config.h and a few valid ares_config.h files. This is the same general approach used still, but ares_config.h and ares_build.h are supplied to cares.BUILD from the only remaining local_repository, which serves only to export these two header files.
Diffstat (limited to 'WORKSPACE')
-rw-r--r--WORKSPACE61
1 files changed, 37 insertions, 24 deletions
diff --git a/WORKSPACE b/WORKSPACE
index 907cef1fca..8734ad1564 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -10,7 +10,7 @@ bind(
bind(
name = "zlib",
- actual = "@submodule_zlib//:z",
+ actual = "@com_github_madler_zlib//:z",
)
bind(
@@ -30,22 +30,22 @@ bind(
bind(
name = "cares",
- actual = "@submodule_cares//:ares",
+ actual = "@com_github_cares_cares//:ares",
)
bind(
name = "gtest",
- actual = "@submodule_gtest//:gtest",
+ actual = "@com_github_google_googletest//:gtest",
)
bind(
name = "gmock",
- actual = "@submodule_gtest//:gmock",
+ actual = "@com_github_google_googletest//:gmock",
)
bind(
name = "benchmark",
- actual = "@submodule_benchmark//:benchmark",
+ actual = "@com_github_google_benchmark//:benchmark",
)
bind(
@@ -53,47 +53,60 @@ bind(
actual = "@com_github_gflags_gflags//:gflags",
)
-local_repository(
+http_archive(
name = "boringssl",
- path = "third_party/boringssl-with-bazel",
+ # on the master-with-bazel branch
+ url = "https://boringssl.googlesource.com/boringssl/+archive/886e7d75368e3f4fab3f4d0d3584e4abfc557755.tar.gz",
)
-new_local_repository(
- name = "submodule_zlib",
+new_http_archive(
+ name = "com_github_madler_zlib",
build_file = "third_party/zlib.BUILD",
- path = "third_party/zlib",
+ strip_prefix = "zlib-cacf7f1d4e3d44d871b605da3b647f07d718623f",
+ url = "https://github.com/madler/zlib/archive/cacf7f1d4e3d44d871b605da3b647f07d718623f.tar.gz",
)
-new_local_repository(
+http_archive(
name = "com_google_protobuf",
- build_file = "third_party/protobuf/BUILD",
- path = "third_party/protobuf",
+ strip_prefix = "protobuf-80a37e0782d2d702d52234b62dd4b9ec74fd2c95",
+ url = "https://github.com/google/protobuf/archive/80a37e0782d2d702d52234b62dd4b9ec74fd2c95.tar.gz",
)
-new_local_repository(
- name = "submodule_gtest",
+new_http_archive(
+ name = "com_github_google_googletest",
build_file = "third_party/gtest.BUILD",
- path = "third_party/googletest",
+ strip_prefix = "googletest-ec44c6c1675c25b9827aacd08c02433cccde7780",
+ url = "https://github.com/google/googletest/archive/ec44c6c1675c25b9827aacd08c02433cccde7780.tar.gz",
)
-local_repository(
+http_archive(
name = "com_github_gflags_gflags",
- path = "third_party/gflags",
+ strip_prefix = "gflags-30dbc81fb5ffdc98ea9b14b1918bfe4e8779b26e",
+ url = "https://github.com/gflags/gflags/archive/30dbc81fb5ffdc98ea9b14b1918bfe4e8779b26e.tar.gz",
)
-new_local_repository(
- name = "submodule_benchmark",
- path = "third_party/benchmark",
+new_http_archive(
+ name = "com_github_google_benchmark",
build_file = "third_party/benchmark.BUILD",
+ strip_prefix = "benchmark-44c25c892a6229b20db7cd9dc05584ea865896de",
+ url = "https://github.com/google/benchmark/archive/44c25c892a6229b20db7cd9dc05584ea865896de.tar.gz",
)
new_local_repository(
- name = "submodule_cares",
+ name = "cares_local_files",
+ build_file = "third_party/cares/cares_local_files.BUILD",
path = "third_party/cares",
+)
+
+new_http_archive(
+ name = "com_github_cares_cares",
build_file = "third_party/cares/cares.BUILD",
+ strip_prefix = "c-ares-3be1924221e1326df520f8498d704a5c4c8d0cce",
+ url = "https://github.com/c-ares/c-ares/archive/3be1924221e1326df520f8498d704a5c4c8d0cce.tar.gz",
)
-local_repository(
+http_archive(
name = "com_google_absl",
- path = "third_party/abseil-cpp",
+ strip_prefix = "abseil-cpp-cc4bed2d74f7c8717e31f9579214ab52a9c9c610",
+ url = "https://github.com/abseil/abseil-cpp/archive/cc4bed2d74f7c8717e31f9579214ab52a9c9c610.tar.gz",
)