]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
cmake: support COMPONENTS param in Findpmem.cmake
authorKefu Chai <kchai@redhat.com>
Fri, 5 Mar 2021 06:04:23 +0000 (14:04 +0800)
committerKefu Chai <kchai@redhat.com>
Sat, 6 Mar 2021 04:25:37 +0000 (12:25 +0800)
commit48e4cd190f65ed92fa9ca41b147621b46b4ea278
treeaa4847629cc936fb19d50dc4542c124c36be5299
parent3e991ad1dbd8bf32175294500c38175bfb0038a7
cmake: support COMPONENTS param in Findpmem.cmake

add two components: pmem and pmemobj to this package. so we can find
them and link against them in a more intuitive way.

before this change the COMPONENTS parameter passed to

find_package(pmem ...)

is dropped on the floor and ignored.

after this change, it is checked and taken into consideration.

also, in this change, the exposed variables are renamed from

PMEM_* to pmem_*

to be consistent with the package name. it's encouraged to be consistent
with the package name when it comes to the INCLUDE_DIR and LIBRARIES
variable names.

Signed-off-by: Kefu Chai <kchai@redhat.com>
cmake/modules/Findpmem.cmake