You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by ko...@apache.org on 2022/05/14 20:06:38 UTC

[arrow] branch master updated: ARROW-16572: [C++] Fix LZ4 build for external projects

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

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


The following commit(s) were added to refs/heads/master by this push:
     new 5c684c2074 ARROW-16572: [C++] Fix LZ4 build for external projects
5c684c2074 is described below

commit 5c684c20748aa9b8fca9ccd1fa5375ebadb0ff20
Author: Hamish Nicholson <hm...@gmail.com>
AuthorDate: Sun May 15 05:05:41 2022 +0900

    ARROW-16572: [C++] Fix LZ4 build for external projects
    
    The use of CMAKE_SOURCE_DIR is not compatible with projects that build arrow from source as a CMake project dependency.
    
    Closes #13154 from Shamazo/master
    
    Authored-by: Hamish Nicholson <hm...@gmail.com>
    Signed-off-by: Sutou Kouhei <ko...@clear-code.com>
---
 cpp/cmake_modules/ThirdpartyToolchain.cmake | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake b/cpp/cmake_modules/ThirdpartyToolchain.cmake
index 992c2102d2..158be06d7d 100644
--- a/cpp/cmake_modules/ThirdpartyToolchain.cmake
+++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake
@@ -2318,7 +2318,7 @@ macro(build_lz4)
     set(LZ4_STATIC_LIB "${LZ4_BUILD_DIR}/lib/liblz4.a")
     # Must explicitly invoke sh on MinGW
     set(LZ4_BUILD_COMMAND
-        BUILD_COMMAND sh "${CMAKE_SOURCE_DIR}/build-support/build-lz4-lib.sh"
+        BUILD_COMMAND sh "${CMAKE_CURRENT_SOURCE_DIR}/build-support/build-lz4-lib.sh"
         "AR=${CMAKE_AR}" "OS=${CMAKE_SYSTEM_NAME}")
   endif()