1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

Added the support for pkgconf when finding system thrift

as fedora uses pkgconf to help locate the thrift files during
compilation instead of a Thrift.cmake file. I have added this logic in
such a way that the existing logic should not be affected. Therefore
enabling the use of system thrift even without pkgconf.
This commit is contained in:
Pavol Sloboda
2025-07-16 10:42:08 +02:00
committed by Leonid Fedorov
parent ee3830f459
commit d0ee5dae32

View File

@ -12,7 +12,17 @@ if(WITH_THRIFT STREQUAL "system" OR WITH_THRIFT STREQUAL "auto")
set(THRIFT_LIBRARY "${THRIFT_LIBRARIES}")
return()
elseif(WITH_THRIFT STREQUAL "system")
message(FATAL_ERROR "System Thrift requested but not found!")
FIND_PACKAGE(PkgConfig REQUIRED)
pkg_check_modules(THRIFT REQUIRED thrift)
if(THRIFT_FOUND)
add_custom_target(external_thrift)
set(THRIFT_INCLUDE_DIR "${THRIFT_INCLUDE_DIR}")
set(THRIFT_LIBRARY "${THRIFT_LIBRARIES}")
return()
else()
message(FATAL_ERROR "System Thrift requested but not found!")
endif()
endif()
endif()