Skip to content

Commit 39a1c44

Browse files
author
donghuixu
committed
add linkopts and protoc_lib in deps
1 parent ab65fb0 commit 39a1c44

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

BUILD

+17-1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,15 @@ COPTS = [
1818
"-DGFLAGS_NS=google",
1919
]
2020

21+
LINKOPTS = [
22+
"-lpthread",
23+
"-lrt",
24+
"-lssl",
25+
"-lcrypto",
26+
"-ldl",
27+
"-lz",
28+
]
29+
2130
genrule(
2231
name = "config_h",
2332
outs = [
@@ -154,7 +163,7 @@ BUTIL_SRCS = [
154163
"src/butil/containers/case_ignored_flat_map.cpp",
155164
"src/butil/iobuf.cpp",
156165
"src/butil/popen.cpp",
157-
]
166+
]
158167

159168

160169
cc_library(
@@ -179,6 +188,7 @@ cc_library(
179188
"src/",
180189
],
181190
copts = COPTS,
191+
linkopts = LINKOPTS,
182192
)
183193

184194
cc_library(
@@ -199,6 +209,7 @@ cc_library(
199209
":butil",
200210
],
201211
copts = COPTS,
212+
linkopts = LINKOPTS,
202213
)
203214

204215
cc_library(
@@ -218,6 +229,7 @@ cc_library(
218229
":bvar",
219230
],
220231
copts = COPTS,
232+
linkopts = LINKOPTS,
221233
)
222234

223235
cc_library(
@@ -235,6 +247,7 @@ cc_library(
235247
":butil",
236248
],
237249
copts = COPTS,
250+
linkopts = LINKOPTS,
238251
)
239252

240253
cc_library(
@@ -251,8 +264,10 @@ cc_library(
251264
deps = [
252265
":butil",
253266
":cc_brpc_internal_proto",
267+
"@com_google_protobuf//:protoc_lib",
254268
],
255269
copts = COPTS,
270+
linkopts = LINKOPTS,
256271
)
257272

258273
brpc_proto_library(
@@ -291,6 +306,7 @@ cc_library(
291306
"@com_github_google_leveldb//:leveldb",
292307
],
293308
copts = COPTS,
309+
linkopts = LINKOPTS,
294310
visibility = ["//visibility:public"],
295311
)
296312

0 commit comments

Comments
 (0)