From d72c2d9811a12d2e2892ebc8ebe830f06763c370 Mon Sep 17 00:00:00 2001 From: Sutou Kouhei Date: Wed, 28 Jun 2023 06:19:52 +0900 Subject: [PATCH] xxx --- ci/scripts/cpp_build.sh | 2 +- cpp/Brewfile | 2 +- cpp/cmake_modules/FindOpenSSLAlt.cmake | 23 +++++++++++++++-------- 3 files changed, 17 insertions(+), 10 deletions(-) diff --git a/ci/scripts/cpp_build.sh b/ci/scripts/cpp_build.sh index 2ef9c0ee225ea..96cd2be8fa87d 100755 --- a/ci/scripts/cpp_build.sh +++ b/ci/scripts/cpp_build.sh @@ -171,7 +171,7 @@ cmake \ ${source_dir} export CMAKE_BUILD_PARALLEL_LEVEL=${CMAKE_BUILD_PARALLEL_LEVEL:-$[${n_jobs} + 1]} -time cmake --build . --target install +time cmake --build . --target install --verbose popd diff --git a/cpp/Brewfile b/cpp/Brewfile index 66f1bd332bbf9..580e8d3f115d5 100644 --- a/cpp/Brewfile +++ b/cpp/Brewfile @@ -30,7 +30,7 @@ brew "grpc" brew "llvm@14" brew "lz4" brew "ninja" -brew "openssl@1.1" +brew "openssl@3" brew "protobuf" brew "python" brew "rapidjson" diff --git a/cpp/cmake_modules/FindOpenSSLAlt.cmake b/cpp/cmake_modules/FindOpenSSLAlt.cmake index f027eb1026dde..de56e1bc0b8ce 100644 --- a/cpp/cmake_modules/FindOpenSSLAlt.cmake +++ b/cpp/cmake_modules/FindOpenSSLAlt.cmake @@ -22,17 +22,24 @@ endif() if(APPLE AND NOT OPENSSL_ROOT_DIR) find_program(BREW brew) if(BREW) - execute_process(COMMAND ${BREW} --prefix "openssl@1.1" - OUTPUT_VARIABLE OPENSSL11_BREW_PREFIX + execute_process(COMMAND ${BREW} --prefix "openssl" + OUTPUT_VARIABLE OPENSSL_BREW_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE) - if(OPENSSL11_BREW_PREFIX) - set(OPENSSL_ROOT_DIR ${OPENSSL11_BREW_PREFIX}) + if(OPENSSL_BREW_PREFIX) + set(OPENSSL_ROOT_DIR ${OPENSSL_BREW_PREFIX}) else() - execute_process(COMMAND ${BREW} --prefix "openssl" - OUTPUT_VARIABLE OPENSSL_BREW_PREFIX + execute_process(COMMAND ${BREW} --prefix "openssl@3.0" + OUTPUT_VARIABLE OPENSSL3_BREW_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE) - if(OPENSSL_BREW_PREFIX) - set(OPENSSL_ROOT_DIR ${OPENSSL_BREW_PREFIX}) + if(OPENSSL11_BREW_PREFIX) + set(OPENSSL_ROOT_DIR ${OPENSSL3_BREW_PREFIX}) + else() + execute_process(COMMAND ${BREW} --prefix "openssl@1.1" + OUTPUT_VARIABLE OPENSSL11_BREW_PREFIX + OUTPUT_STRIP_TRAILING_WHITESPACE) + if(OPENSSL11_BREW_PREFIX) + set(OPENSSL_ROOT_DIR ${OPENSSL11_BREW_PREFIX}) + endif() endif() endif() endif()