kou commented on code in PR #43219:
URL: https://github.com/apache/arrow/pull/43219#discussion_r1673283755
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -4135,6 +4107,23 @@ macro(build_grpc)
endif()
endmacro()
+if(ARROW_WITH_GOOGLE_CLOUD_CPP OR ARROW_WITH_GRPC)
+ # Google Cloud C++ SDK and gRPC require Google Abseil
+ resolve_dependency(absl
+ ARROW_CMAKE_PACKAGE_NAME
+ ArrowFlight
+ ARROW_PC_PACKAGE_NAME
+ arrow-flight
Review Comment:
```suggestion
if(ARROW_WITH_GOOGLE_CLOUD_CPP)
set(ARROW_ABSL_CMAKE_PACKAGE_NAME Arrow)
set(ARROW_ABSL_PC_PACKAGE_NAME arrow)
else()
set(ARROW_ABSL_CMAKE_PACKAGE_NAME ArrowFlight)
set(ARROW_ABSL_PC_PACKAGE_NAME arrow-flight)
endif()
resolve_dependency(absl
ARROW_CMAKE_PACKAGE_NAME
${ARROW_ABSL_CMAKE_PACKAGE_NAME}
ARROW_PC_PACKAGE_NAME
${ARROW_ABSL_PC_PACKAGE_NAME}
```
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -4135,6 +4107,23 @@ macro(build_grpc)
endif()
endmacro()
+if(ARROW_WITH_GOOGLE_CLOUD_CPP OR ARROW_WITH_GRPC)
+ # Google Cloud C++ SDK and gRPC require Google Abseil
+ resolve_dependency(absl
+ ARROW_CMAKE_PACKAGE_NAME
+ ArrowFlight
+ ARROW_PC_PACKAGE_NAME
+ arrow-flight
+ HAVE_ALT
+ FALSE
+ FORCE_ANY_NEWER_VERSION
+ TRUE
+ PC_PACKAGE_NAMES
+ absl
Review Comment:
We can't use this because Abseil provides `absl_*.pc` not `absl.pc`.
```suggestion
```
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -4135,6 +4107,23 @@ macro(build_grpc)
endif()
endmacro()
+if(ARROW_WITH_GOOGLE_CLOUD_CPP OR ARROW_WITH_GRPC)
+ # Google Cloud C++ SDK and gRPC require Google Abseil
+ resolve_dependency(absl
+ ARROW_CMAKE_PACKAGE_NAME
+ ArrowFlight
+ ARROW_PC_PACKAGE_NAME
+ arrow-flight
+ HAVE_ALT
+ FALSE
+ FORCE_ANY_NEWER_VERSION
+ TRUE
+ PC_PACKAGE_NAMES
+ absl
+ REQUIRED_VERSION
+ ${ARROW_ABSL_REQUIRED_VERSION})
Review Comment:
Could you define this as `20211102` or use `20211102` directly here?
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -2874,33 +2874,6 @@ endmacro()
# ----------------------------------------------------------------------
# Dependencies for Arrow Flight RPC
-macro(ensure_absl)
- if(NOT absl_FOUND)
- if(${absl_SOURCE} STREQUAL "AUTO")
- # We can't use resolve_dependency(absl 20211102) to use Abseil
- # 20211102 or later because Abseil's CMake package uses "EXACT"
Review Comment:
Yes. `resolve_dependency(FORCE_ANY_NEWER_VERSION TRUE)` should work.
--
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]