You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by mm...@apache.org on 2021/04/08 18:01:07 UTC

[pulsar] branch master updated: [C++] Add /opt/homebrew/ as a possible path for OpenSSL on Mac (#10141)

This is an automated email from the ASF dual-hosted git repository.

mmerli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/master by this push:
     new dd19702  [C++] Add /opt/homebrew/ as a possible path for OpenSSL on Mac (#10141)
dd19702 is described below

commit dd19702aff14c2857f46701b2a435694af31ba6d
Author: Matteo Merli <mm...@apache.org>
AuthorDate: Thu Apr 8 11:00:01 2021 -0700

    [C++] Add /opt/homebrew/ as a possible path for OpenSSL on Mac (#10141)
---
 pulsar-client-cpp/CMakeLists.txt | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/pulsar-client-cpp/CMakeLists.txt b/pulsar-client-cpp/CMakeLists.txt
index 7cb3e4c..260f2c9 100644
--- a/pulsar-client-cpp/CMakeLists.txt
+++ b/pulsar-client-cpp/CMakeLists.txt
@@ -91,8 +91,8 @@ set(OPENSSL_ROOT_DIR /usr/lib64/)
 ### This part is to find and keep SSL dynamic libs in RECORD_OPENSSL_SSL_LIBRARY and RECORD_OPENSSL_CRYPTO_LIBRARY
 ### After find the libs, will unset related cache, and will not affact another same call to find_package.
 if (APPLE)
-    set(OPENSSL_INCLUDE_DIR /usr/local/opt/openssl/include/)
-    set(OPENSSL_ROOT_DIR /usr/local/opt/openssl/)
+    set(OPENSSL_INCLUDE_DIR /usr/local/opt/openssl/include/ /opt/homebrew/opt/openssl/include)
+    set(OPENSSL_ROOT_DIR /usr/local/opt/openssl/ /opt/homebrew/opt/openssl)
 endif ()
 
 set(OPENSSL_USE_STATIC_LIBS FALSE)
@@ -226,11 +226,6 @@ if (BUILD_PYTHON_WRAPPER)
     find_package(Boost REQUIRED COMPONENTS ${BOOST_PYTHON_NAME_FOUND})
 endif (BUILD_PYTHON_WRAPPER)
 
-if (APPLE)
-    set(OPENSSL_INCLUDE_DIR /usr/local/opt/openssl/include/)
-    set(OPENSSL_ROOT_DIR /usr/local/opt/openssl/)
-endif ()
-
 find_package(OpenSSL REQUIRED)
 
 if (BUILD_TESTS)