vcpkg/ports/h5py-lzf/CMakeLists.txt
zi-m 430a10ff35
[h5py-lzf] Add new port (#10871)
* [h5py-lzf] Add new port

* add 0001-disable-H5PLget_plugin-api.patch

fix "error: static declaration of 'H5PLget_plugin_info' follows non-static declaration"
2020-05-13 16:59:31 -07:00

12 lines
561 B
CMake

cmake_minimum_required(VERSION 3.13)
project(h5py-lzf)
find_package(hdf5 CONFIG REQUIRED)
add_library(h5py-lzf STATIC lzf_filter.c lzf/lzf_c.c lzf/lzf_d.c)
target_include_directories(h5py-lzf PUBLIC $<INSTALL_INTERFACE:include>)
target_link_libraries(h5py-lzf PRIVATE libzstd $<IF:${link_hdf5_SHARED},hdf5::hdf5-shared,hdf5::hdf5-static>)
install(TARGETS h5py-lzf EXPORT h5py-lzf-config ARCHIVE DESTINATION lib LIBRARY DESTINATION lib)
install(EXPORT h5py-lzf-config DESTINATION share/cmake/h5py-lzf)
install(FILES lzf_filter.h lzf/lzf.h DESTINATION include)