kou commented on issue #33882:
URL: https://github.com/apache/arrow/issues/33882#issuecomment-1407308357
Could you try this?
```diff
diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake
b/cpp/cmake_modules/ThirdpartyToolchain.cmake
index 4310d6018b..5a88900fe9 100644
--- a/cpp/cmake_modules/ThirdpartyToolchain.cmake
+++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake
@@ -286,14 +286,17 @@ macro(resolve_dependency DEPENDENCY_NAME)
endif()
if(${DEPENDENCY_NAME}_SOURCE STREQUAL "SYSTEM" AND
ARG_IS_RUNTIME_DEPENDENCY)
provide_find_module(${PACKAGE_NAME} "Arrow")
+ message(STATUS "Before find_package(PkgConfig)")
list(APPEND ARROW_SYSTEM_DEPENDENCIES ${PACKAGE_NAME})
find_package(PkgConfig QUIET)
+ message(STATUS "After find_package(PkgConfig)")
foreach(ARG_PC_PACKAGE_NAME ${ARG_PC_PACKAGE_NAMES})
pkg_check_modules(${ARG_PC_PACKAGE_NAME}_PC
${ARG_PC_PACKAGE_NAME}
NO_CMAKE_PATH
NO_CMAKE_ENVIRONMENT_PATH
QUIET)
+ message(STATUS "After pkg_check_modules(${ARG_PC_PACKAGE_NAME})")
if(${${ARG_PC_PACKAGE_NAME}_PC_FOUND})
message(STATUS "Using pkg-config package for ${ARG_PC_PACKAGE_NAME}
for static link"
)
```
> Can we just disable the whole pkg-config search completely? Our builds
have CMake metadata, and `find_package(${PACKAGE_NAME} REQUIRED)` should work
in the vast majority of cases (even moreso with `CONFIG` mode), and especially
for gprc.
We can add an option to disable pkg-config support. But if we disable
pkg-config support, conda users can't find Apache Arrow C++ by pkg-config. I'm
not familiar with conda but I think that there are users who use pkg-config to
find external packages.
--
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]