From 3c1a726fffaa9fca6faa5894d3fcd941863559de Mon Sep 17 00:00:00 2001 From: wenweihu86 Date: Wed, 19 Jun 2019 16:37:09 +0800 Subject: [PATCH] update openssl path --- config_brpc.sh | 16 ++++++++++------ docs/cn/getting_started.md | 2 +- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/config_brpc.sh b/config_brpc.sh index c5970fd1f9..c236c05064 100755 --- a/config_brpc.sh +++ b/config_brpc.sh @@ -136,12 +136,16 @@ find_dir_of_header_or_die() { $ECHO $dir } -# User specified path of openssl, if not given it's empty -OPENSSL_LIB=$(find_dir_of_lib ssl) - -# Inconvenient to check these headers in baidu-internal -#PTHREAD_HDR=$(find_dir_of_header_or_die pthread.h) -OPENSSL_HDR=$(find_dir_of_header_or_die openssl/ssl.h) +if [ "$SYSTEM" = "Darwin" ]; then + OPENSSL_LIB="/usr/local/opt/openssl/lib" + OPENSSL_HDR="/usr/local/opt/openssl/include" +else + # User specified path of openssl, if not given it's empty + OPENSSL_LIB=$(find_dir_of_lib ssl) + # Inconvenient to check these headers in baidu-internal + #PTHREAD_HDR=$(find_dir_of_header_or_die pthread.h) + OPENSSL_HDR=$(find_dir_of_header_or_die openssl/ssl.h) +fi if [ $WITH_MESALINK != 0 ]; then MESALINK_HDR=$(find_dir_of_header_or_die mesalink/openssl/ssl.h) diff --git a/docs/cn/getting_started.md b/docs/cn/getting_started.md index 9369d8312e..dbab05c306 100644 --- a/docs/cn/getting_started.md +++ b/docs/cn/getting_started.md @@ -278,7 +278,7 @@ git clone https://github.com/google/googletest && cd googletest/googletest && mk ### Compile brpc with config_brpc.sh git clone brpc, cd into the repo and run ```shell -$ sh config_brpc.sh --headers=/usr/local --libs=/usr/local --cc=clang --cxx=clang++ +$ sh config_brpc.sh --headers=/usr/local/include --libs=/usr/local/lib --cc=clang --cxx=clang++ $ make ``` To not link debugging symbols, add `--nodebugsymbols` and compiled binaries will be much smaller.