]> git.proxmox.com Git - ceph.git/blame - ceph/src/rocksdb/cmake/modules/FindNUMA.cmake
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / rocksdb / cmake / modules / FindNUMA.cmake
CommitLineData
11fdf7f2
TL
1# - Find NUMA
2# Find the NUMA library and includes
3#
f67539c2 4# NUMA_INCLUDE_DIRS - where to find numa.h, etc.
11fdf7f2
TL
5# NUMA_LIBRARIES - List of libraries when using NUMA.
6# NUMA_FOUND - True if NUMA found.
7
f67539c2 8find_path(NUMA_INCLUDE_DIRS
11fdf7f2
TL
9 NAMES numa.h numaif.h
10 HINTS ${NUMA_ROOT_DIR}/include)
11
12find_library(NUMA_LIBRARIES
13 NAMES numa
14 HINTS ${NUMA_ROOT_DIR}/lib)
15
16include(FindPackageHandleStandardArgs)
f67539c2 17find_package_handle_standard_args(NUMA DEFAULT_MSG NUMA_LIBRARIES NUMA_INCLUDE_DIRS)
11fdf7f2
TL
18
19mark_as_advanced(
20 NUMA_LIBRARIES
f67539c2
TL
21 NUMA_INCLUDE_DIRS)
22
23if(NUMA_FOUND AND NOT (TARGET NUMA::NUMA))
24 add_library (NUMA::NUMA UNKNOWN IMPORTED)
25 set_target_properties(NUMA::NUMA
26 PROPERTIES
27 IMPORTED_LOCATION ${NUMA_LIBRARIES}
28 INTERFACE_INCLUDE_DIRECTORIES ${NUMA_INCLUDE_DIRS})
29endif()