You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by ra...@apache.org on 2023/07/17 13:20:14 UTC

[arrow] 02/02: GH-36707: [C++] Use ARROW_PACKAGE_PREFIX for OPENSSL_ROOT_DIR too (#36710)

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

raulcd pushed a commit to branch maint-13.0.0
in repository https://gitbox.apache.org/repos/asf/arrow.git

commit 453965d223c14fd893d69a911df8de70794ae605
Author: Sutou Kouhei <ko...@clear-code.com>
AuthorDate: Mon Jul 17 22:18:18 2023 +0900

    GH-36707: [C++] Use ARROW_PACKAGE_PREFIX for OPENSSL_ROOT_DIR too (#36710)
    
    ### Rationale for this change
    
    In general, a CMake package uses `${PACKAGE}_ROOT` variable to detect `PACKAGE` but `FindOpenSSL.cmake` uses `OPENSSL_ROOT_DIR` not `OpenSSL_ROOT`.
    
    ### What changes are included in this PR?
    
    Set `OPENSSL_ROOT_DIR` explicitly.
    
    ### Are these changes tested?
    
    Yes.
    
    ### Are there any user-facing changes?
    
    Yes.
    * Closes: #36707
    
    Authored-by: Sutou Kouhei <ko...@clear-code.com>
    Signed-off-by: Raúl Cumplido <ra...@gmail.com>
---
 cpp/cmake_modules/ThirdpartyToolchain.cmake | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake b/cpp/cmake_modules/ThirdpartyToolchain.cmake
index 6488ac13cb..456276abda 100644
--- a/cpp/cmake_modules/ThirdpartyToolchain.cmake
+++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake
@@ -138,6 +138,9 @@ if(ARROW_PACKAGE_PREFIX)
   if(NOT ENV{Boost_ROOT})
     set(ENV{Boost_ROOT} ${ARROW_PACKAGE_PREFIX})
   endif()
+  if(NOT DEFINED OPENSSL_ROOT_DIR)
+    set(OPENSSL_ROOT_DIR ${ARROW_PACKAGE_PREFIX})
+  endif()
 endif()
 
 # For each dependency, set dependency source to global default, if unset