Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
brpc
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
brpc
Commits
862be4e1
Commit
862be4e1
authored
Aug 07, 2019
by
Yiming Jing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Link MesaLink in bazel if enabled
parent
4adb6894
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
9 deletions
+25
-9
.travis.yml
.travis.yml
+4
-4
BUILD
BUILD
+17
-3
CMakeLists.txt
CMakeLists.txt
+2
-0
build_in_travis_ci.sh
build_in_travis_ci.sh
+2
-2
No files found.
.travis.yml
View file @
862be4e1
...
...
@@ -11,10 +11,10 @@ env:
-
PURPOSE=unittest
-
PURPOSE=compile-with-cmake
-
PURPOSE=compile-with-bazel
-
PURPOSE=compile USE_MESALINK=
yes
-
PURPOSE=unittest USE_MESALINK=
yes
-
PURPOSE=compile-with-cmake USE_MESALINK=
yes
-
PURPOSE=compile-with-bazel USE_MESALINK=
yes
-
PURPOSE=compile USE_MESALINK=
true
-
PURPOSE=unittest USE_MESALINK=
true
-
PURPOSE=compile-with-cmake USE_MESALINK=
true
-
PURPOSE=compile-with-bazel USE_MESALINK=
true
before_script
:
-
ulimit -c unlimited -S
# enable core dumps
...
...
BUILD
View file @
862be4e1
...
...
@@ -10,6 +10,12 @@ config_setting(
visibility = ["//visibility:public"],
)
config_setting(
name = "with_mesalink",
define_values = {"with_mesalink": "true"},
visibility = ["//visibility:public"],
)
config_setting(
name = "with_thrift",
define_values = {"with_thrift": "true"},
...
...
@@ -46,6 +52,9 @@ COPTS = [
] + select({
":with_glog": ["-DBRPC_WITH_GLOG=1"],
"//conditions:default": ["-DBRPC_WITH_GLOG=0"],
}) + select({
":with_mesalink": ["-DUSE_MESALINK"],
"//conditions:default": [""],
}) + select({
":with_thrift": ["-DENABLE_THRIFT_FRAMED_PROTOCOL=1"],
"//conditions:default": [""],
...
...
@@ -54,7 +63,7 @@ COPTS = [
LINKOPTS = [
"-lpthread",
"-ldl",
"-lz",
"-lz",
"-lssl",
"-lcrypto",
] + select({
...
...
@@ -73,6 +82,11 @@ LINKOPTS = [
"//conditions:default": [
"-lrt",
],
}) + select({
":with_mesalink": [
"-lmesalink",
],
"//conditions:default": [],
}) + select({
":with_thrift": [
"-lthriftnb",
...
...
@@ -236,7 +250,7 @@ objc_library(
"src/butil/atomicops.h",
"src/butil/atomicops_internals_atomicword_compat.h",
"src/butil/atomicops_internals_mac.h",
"src/butil/base_export.h",
"src/butil/base_export.h",
"src/butil/basictypes.h",
"src/butil/build_config.h",
"src/butil/compat.h",
...
...
@@ -270,7 +284,7 @@ objc_library(
"src/butil/strings/sys_string_conversions.h",
"src/butil/synchronization/lock.h",
"src/butil/time/time.h",
"src/butil/time.h",
"src/butil/time.h",
"src/butil/third_party/dynamic_annotations/dynamic_annotations.h",
"src/butil/threading/platform_thread.h",
"src/butil/threading/thread_restrictions.h",
...
...
CMakeLists.txt
View file @
862be4e1
...
...
@@ -146,6 +146,8 @@ if(WITH_MESALINK)
find_library
(
MESALINK_LIB NAMES mesalink
)
if
((
NOT MESALINK_INCLUDE_PATH
)
OR
(
NOT MESALINK_LIB
))
message
(
FATAL_ERROR
"Fail to find MesaLink"
)
else
()
message
(
STATUS
"Found MesaLink:
${
MESALINK_LIB
}
"
)
endif
()
include_directories
(
${
MESALINK_INCLUDE_PATH
}
)
endif
()
...
...
build_in_travis_ci.sh
View file @
862be4e1
...
...
@@ -23,7 +23,7 @@ echo "build combination: PURPOSE=$PURPOSE CXX=$CXX CC=$CC"
init_make_config
()
{
EXTRA_BUILD_OPTS
=
""
if
[
"
$USE_MESALINK
"
=
"
yes
"
]
;
then
if
[
"
$USE_MESALINK
"
=
"
true
"
]
;
then
EXTRA_BUILD_OPTS
=
"
$EXTRA_BUILD_OPTS
--with-mesalink"
fi
...
...
@@ -42,7 +42,7 @@ elif [ "$PURPOSE" = "unittest" ]; then
elif
[
"
$PURPOSE
"
=
"compile-with-cmake"
]
;
then
rm
-rf
bld
&&
mkdir
bld
&&
cd
bld
&&
cmake
-DWITH_MESALINK
=
"
$USE_MESALINK
"
..
&&
make
-j4
elif
[
"
$PURPOSE
"
=
"compile-with-bazel"
]
;
then
bazel build
-j
12
-c
opt
--copt
-DHAVE_ZLIB
=
1 //...
bazel build
-j
12
-c
opt
--
define
with_mesalink
=
"
$USE_MESALINK
"
--
copt
-DHAVE_ZLIB
=
1 //...
else
echo
"Unknown purpose=
\"
$PURPOSE
\"
"
fi
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment