kou commented on PR #48333:
URL: https://github.com/apache/arrow/pull/48333#issuecomment-3634803129
Could you try this?
```diff
diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake
b/cpp/cmake_modules/ThirdpartyToolchain.cmake
index 28e984f95d..ffc0e17f75 100644
--- a/cpp/cmake_modules/ThirdpartyToolchain.cmake
+++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake
@@ -3293,9 +3293,12 @@ function(build_crc32c_once)
set(CRC32C_BUILD_TESTS OFF)
set(CRC32C_BUILD_BENCHMARKS OFF)
set(CRC32C_USE_GLOG OFF)
- set(CRC32C_INSTALL OFF)
fetchcontent_makeavailable(crc32c)
+ if(CMAKE_VERSION VERSION_LESS 3.28)
+ set_property(DIRECTORY ${crc32_SOURCE_DIR} PROPERTY EXCLUDE_FROM_ALL
TRUE)
+ endif()
+
# Create alias target for consistency (crc32c exports as Crc32c::crc32c
when installed)
if(NOT TARGET Crc32c::crc32c)
add_library(Crc32c::crc32c ALIAS crc32c)
@@ -3429,13 +3432,17 @@ function(build_google_cloud_cpp_storage)
set(GOOGLE_CLOUD_CPP_ENABLE_WERROR OFF)
set(GOOGLE_CLOUD_CPP_WITH_MOCKS OFF)
# Disable installation when embedded via FetchContent
- set(GOOGLE_CLOUD_CPP_ENABLE_INSTALL OFF)
+ # set(GOOGLE_CLOUD_CPP_ENABLE_INSTALL OFF)
set(BUILD_TESTING OFF)
# Unity build causes some build errors.
set(CMAKE_UNITY_BUILD FALSE)
fetchcontent_makeavailable(google_cloud_cpp)
+ if(CMAKE_VERSION VERSION_LESS 3.28)
+ set_property(DIRECTORY ${google_cloud_cpp_SOURCE_DIR} PROPERTY
EXCLUDE_FROM_ALL TRUE)
+ endif()
+
# Remove unused directories to save build directory storage.
# 141MB -> 79MB
file(REMOVE_RECURSE "${google_cloud_cpp_SOURCE_DIR}/ci")
```
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]