1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-18 14:21:49 -05:00
sdrangel/cmake/Modules/FindLZ4.cmake

28 lines
647 B
CMake
Raw Normal View History

INCLUDE(FindPkgConfig)
PKG_CHECK_MODULES(PC_LZ4 "liblz4")
FIND_PATH(LZ4_INCLUDE_DIRS
NAMES lz4.h
HINTS ${PC_LZ4_INCLUDE_DIR}
${CMAKE_INSTALL_PREFIX}/include
${LIBLZ4_INSTALL_PREFIX}/include
PATHS
/usr/local/include
/usr/include
)
FIND_LIBRARY(LZ4_LIBRARIES
NAMES lz4 liblz4
HINTS ${PC_LZ4_LIBDIR}
${CMAKE_INSTALL_PREFIX}/lib
${CMAKE_INSTALL_PREFIX}/lib64
PATHS
${LZ4_INCLUDE_DIRS}/../lib
/usr/local/lib
/usr/lib
)
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZ4 DEFAULT_MSG LZ4_LIBRARIES LZ4_INCLUDE_DIRS)
MARK_AS_ADVANCED(LZ4_LIBRARIES LZ4_INCLUDE_DIRS)