FightingMan commented on issue #1378:
URL: https://github.com/apache/incubator-brpc/issues/1378#issuecomment-818725158
update:
copy全部buildfile到本地,以及修改本地WORKSPACE文件能解决
期待提供一共fucntion,load一下即可
(base) [ /tmp/test_brpc]$ ls
BUILD WORKSPACE bazel-bin bazel-out bazel-test_brpc bazel-testlogs
glog.BUILD leveldb.BUILD openssl.BUILD test.cpp zlib.BUILD
(base) [/tmp/test_brpc]$ !cat
cat WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load('@bazel_tools//tools/build_defs/repo:git.bzl', 'git_repository')
git_repository(
name = "brpc_cpp",
remote = "https://github.com/apache/incubator-brpc.git",
branch = "master",
)
skylib_version = "0.8.0"
http_archive(
name = "bazel_skylib",
type = "tar.gz",
url =
"https://github.com/bazelbuild/bazel-skylib/releases/download/{}/bazel-skylib.{}.tar.gz".format
(skylib_version, skylib_version),
sha256 =
"2ef429f5d7ce7111263289644d233707dba35e39696377ebab8b0bc701f7818e",
)
http_archive(
name = "com_google_protobuf",
strip_prefix = "protobuf-3.6.1.3",
sha256 =
"9510dd2afc29e7245e9e884336f848c8a6600a14ae726adb6befdb4f786f0be2",
type = "zip",
url = "https://github.com/protocolbuffers/protobuf/archive/v3.6.1.3.zip",
)
http_archive(
name = "com_github_gflags_gflags",
strip_prefix = "gflags-46f73f88b18aee341538c0dfc22b1710a6abedef",
url =
"https://github.com/gflags/gflags/archive/46f73f88b18aee341538c0dfc22b1710a6abedef.tar.gz",
)
bind(
name = "gflags",
actual = "@com_github_gflags_gflags//:gflags",
)
http_archive(
name = "com_github_google_leveldb",
build_file = "//:leveldb.BUILD",
strip_prefix = "leveldb-a53934a3ae1244679f812d998a4f16f2c7f309a6",
url =
"https://github.com/google/leveldb/archive/a53934a3ae1244679f812d998a4f16f2c7f309a6.tar.gz"
)
http_archive(
name = "com_github_google_glog",
build_file = "//:glog.BUILD",
strip_prefix = "glog-a6a166db069520dbbd653c97c2e5b12e08a8bb26",
url =
"https://github.com/google/glog/archive/a6a166db069520dbbd653c97c2e5b12e08a8bb26.tar.gz"
)
http_archive(
name = "com_google_googletest",
strip_prefix = "googletest-0fe96607d85cf3a25ac40da369db62bbee2939a5",
url =
"https://github.com/google/googletest/archive/0fe96607d85cf3a25ac40da369db62bbee2939a5.tar.gz",
)
new_local_repository(
name = "openssl",
path = "/usr",
build_file = "//:openssl.BUILD",
)
new_local_repository(
name = "openssl_macos",
build_file = "//:openssl.BUILD",
path = "/usr/lib/openssl",
)
bind(
name = "ssl",
actual = "@openssl//:ssl"
)
bind(
name = "ssl_macos",
actual = "@openssl_macos//:ssl"
)
new_local_repository(
name = "zlib",
build_file = "//:zlib.BUILD",
path = "/usr",
)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]