forked from google/nearby
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathWORKSPACE
155 lines (130 loc) · 4.95 KB
/
WORKSPACE
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
# Rule repository, note that it's recommended to use a pinned commit to a released version of the rules
http_archive(
name = "rules_foreign_cc",
strip_prefix = "rules_foreign_cc-0.6.0",
url = "https://github.com/bazelbuild/rules_foreign_cc/archive/0.6.0.tar.gz",
)
load("@rules_foreign_cc//foreign_cc:repositories.bzl", "rules_foreign_cc_dependencies")
# This sets up some common toolchains for building targets. For more details, please see
# https://github.com/bazelbuild/rules_foreign_cc/tree/main/docs#rules_foreign_cc_dependencies
rules_foreign_cc_dependencies()
_ALL_CONTENT = """\
filegroup(
name = "all_srcs",
srcs = glob(["**"]),
visibility = ["//visibility:public"],
)
"""
http_archive(
name = "com_google_absl",
strip_prefix = "abseil-cpp-master",
urls = ["https://github.com/abseil/abseil-cpp/archive/master.zip"],
)
# Using a protobuf javalite version that contains @com_google_protobuf_javalite//:javalite_toolchain
http_archive(
name = "com_google_protobuf_javalite",
strip_prefix = "protobuf-javalite",
urls = ["https://github.com/google/protobuf/archive/javalite.zip"],
)
http_archive(
name = "com_google_protobuf",
strip_prefix = "protobuf-3.17.0",
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.17.0.tar.gz"],
)
http_archive(
name = "com_google_protobuf_cc",
strip_prefix = "protobuf-3.17.0",
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.17.0.tar.gz"],
)
http_archive(
name = "com_google_protobuf_java",
strip_prefix = "protobuf-3.17.0",
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.17.0.tar.gz"],
)
http_archive(
name = "com_google_glog",
sha256 = "f28359aeba12f30d73d9e4711ef356dc842886968112162bc73002645139c39c",
strip_prefix = "glog-0.4.0",
urls = ["https://github.com/google/glog/archive/v0.4.0.tar.gz"],
)
new_local_repository(
name = "com_google_ukey2",
path = "./third_party/ukey2/ukey2",
build_file_content = _ALL_CONTENT,
)
http_archive(
name = "aappleby_smhasher",
strip_prefix = "smhasher-master",
build_file_content = """
package(default_visibility = ["//visibility:public"])
cc_library(
name = "libmurmur3",
srcs = ["src/MurmurHash3.cpp"],
hdrs = ["src/MurmurHash3.h"],
copts = ["-Wno-implicit-fallthrough"],
licenses = ["unencumbered"], # MurmurHash is explicity public-domain
)""",
urls = ["https://github.com/aappleby/smhasher/archive/master.zip"],
)
load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")
# Load common dependencies.
protobuf_deps()
http_archive(
name = "com_google_googletest",
strip_prefix = "googletest-main",
urls = ["https://github.com/google/googletest/archive/main.zip"],
)
http_archive(
name = "com_google_webrtc",
build_file_content = """
package(default_visibility = ["//visibility:public"])
""",
urls = ["https://webrtc.googlesource.com/src/+archive/main.tar.gz"],
)
# gflags needed by glog
http_archive(
name = "com_github_gflags_gflags",
strip_prefix = "gflags-2.2.2",
sha256 = "19713a36c9f32b33df59d1c79b4958434cb005b5b47dc5400a7a4b078111d9b5",
url = "https://github.com/gflags/gflags/archive/v2.2.2.zip",
)
# ----------------------------------------------
# Nisaba: Script processing library from Google:
# ----------------------------------------------
# We depend on some of core C++ libraries from Nisaba and use the fresh code
# from the HEAD. See
# https://github.com/google-research/nisaba
nisaba_version = "main"
http_archive(
name = "com_google_nisaba",
url = "https://github.com/google-research/nisaba/archive/refs/heads/%s.zip" % nisaba_version,
strip_prefix = "nisaba-%s" % nisaba_version,
)
load("@com_google_nisaba//bazel:workspace.bzl", "nisaba_public_repositories")
nisaba_public_repositories()
http_archive(
name = "boringssl", # Must match upstream workspace name.
# Gitiles creates gzip files with an embedded timestamp, so we cannot use
# sha256 to validate the archives. We must rely on the commit hash and
# https. Commits must come from the master-with-bazel branch.
urls = ["https://codeload.github.com/google/boringssl/zip/master-with-bazel"],
strip_prefix = "boringssl-master-with-bazel",
type = "zip",
)
# -------------------------------------------------------------------------
# Protocol buffer matches (should be part of gmock and gtest, but not yet):
# https://github.com/inazarenko/protobuf-matchers
http_archive(
name = "com_github_protobuf_matchers",
urls = ["https://github.com/inazarenko/protobuf-matchers/archive/refs/heads/master.zip"],
strip_prefix = "protobuf-matchers-master",
)
http_archive(
name = "com_googlesource_code_re2",
sha256 = "26155e050b10b5969e986dab35654247a3b1b295e0532880b5a9c13c0a700ceb",
strip_prefix = "re2-2021-06-01",
urls = [
"https://github.com/google/re2/archive/refs/tags/2021-06-01.tar.gz",
],
)