summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorA. Maitland Bottoms <bottoms@debian.org>2020-11-21 13:36:21 -0500
committerMarcus Müller <marcus@hostalia.de>2020-12-19 01:02:10 +0100
commita5e49d9120e8d0d7adf4de792cc3c4bc1a6defbc (patch)
tree7ecd0a15cbdb5f6c3f7b599d02bb2573c149eed5 /cmake
parent7e112bfd12731073ac2970aa97f789abeb6f7e88 (diff)
RPC fixes to allow using Thrift-0.13
Adds ability for master to build with newer Thrift versions by checking availability of thrift include files. (Also spelling fix: Thift -> Thrift) And fix up logging for rpcserver_thrift class.
Diffstat (limited to 'cmake')
-rw-r--r--cmake/Modules/FindTHRIFT.cmake14
1 files changed, 13 insertions, 1 deletions
diff --git a/cmake/Modules/FindTHRIFT.cmake b/cmake/Modules/FindTHRIFT.cmake
index c8c2739888..8cdf8b404a 100644
--- a/cmake/Modules/FindTHRIFT.cmake
+++ b/cmake/Modules/FindTHRIFT.cmake
@@ -72,7 +72,19 @@ ENDIF (CMAKE_CROSSCOMPILING)
# Set to found if we've made it this far
if(THRIFT_INCLUDE_DIRS AND THRIFT_LIBRARIES AND PYTHON_THRIFT_FOUND)
- set(THRIFT_FOUND TRUE CACHE BOOL "If Thift has been found")
+ set(THRIFT_FOUND TRUE CACHE BOOL "If Thrift has been found")
+
+ find_file(THRIFT_HAS_VERSION_H thrift/version.h
+ PATH ${THRIFT_INCLUDE_DIRS} NO_DEFAULT_PATH)
+ if(THRIFT_HAS_VERSION_H-FOUND)
+ set(THRIFT_HAS_VERSION_H TRUE CACHE BOOL "If Thrift has thrift/version.h")
+ endif()
+
+ find_file(THRIFT_HAS_THREADFACTORY_H thrift/concurrency/ThreadFactory.h
+ PATH ${THRIFT_INCLUDE_DIRS} NO_DEFAULT_PATH)
+ if(THRIFT_HAS_THREADFACTORY_H-FOUND)
+ set(THRIFT_HAS_THREADFACTORY_H TRUE CACHE BOOL "If Thrift has thrift/concurrency/ThreadFactory.h")
+ endif()
endif(THRIFT_INCLUDE_DIRS AND THRIFT_LIBRARIES AND PYTHON_THRIFT_FOUND)