cloudflare/ClickHouse
Publicmirrored fromhttps://github.com/cloudflare/ClickHouse
cmake/Modules/Findbtrie.cmake
44lines · modecode
unknown
| 1 | # - Try to find btrie headers and libraries. |
| 2 | # |
| 3 | # Usage of this module as follows: |
| 4 | # |
| 5 | # find_package(btrie) |
| 6 | # |
| 7 | # Variables used by this module, they can change the default behaviour and need |
| 8 | # to be set before calling find_package: |
| 9 | # |
| 10 | # BTRIE_ROOT_DIR Set this variable to the root installation of |
| 11 | # btrie if the module has problems finding |
| 12 | # the proper installation path. |
| 13 | # |
| 14 | # Variables defined by this module: |
| 15 | # |
| 16 | # BTRIE_FOUND System has btrie libs/headers |
| 17 | # BTRIE_LIBRARIES The btrie library/libraries |
| 18 | # BTRIE_INCLUDE_DIR The location of btrie headers |
| 19 | |
| 20 | find_path(BTRIE_ROOT_DIR |
| 21 | NAMES include/btrie.h |
| 22 | ) |
| 23 | |
| 24 | find_library(BTRIE_LIBRARIES |
| 25 | NAMES btrie |
| 26 | PATHS ${BTRIE_ROOT_DIR}/lib ${BTRIE_LIBRARIES_PATHS} |
| 27 | ) |
| 28 | |
| 29 | find_path(BTRIE_INCLUDE_DIR |
| 30 | NAMES btrie.h |
| 31 | PATHS ${BTRIE_ROOT_DIR}/include ${BTRIE_INCLUDE_PATHS} |
| 32 | ) |
| 33 | |
| 34 | include(FindPackageHandleStandardArgs) |
| 35 | find_package_handle_standard_args(btrie DEFAULT_MSG |
| 36 | BTRIE_LIBRARIES |
| 37 | BTRIE_INCLUDE_DIR |
| 38 | ) |
| 39 | |
| 40 | mark_as_advanced( |
| 41 | BTRIE_ROOT_DIR |
| 42 | BTRIE_LIBRARIES |
| 43 | BTRIE_INCLUDE_DIR |
| 44 | ) |