2017-02-28 23:49:04 +00:00
|
|
|
option (USE_INTERNAL_LZ4_LIBRARY "Set to FALSE to use system lz4 library instead of bundled" ${NOT_UNBUNDLED})
|
|
|
|
|
|
|
|
if (NOT USE_INTERNAL_LZ4_LIBRARY)
|
2017-04-01 07:20:54 +00:00
|
|
|
find_library (LZ4_LIBRARY lz4)
|
|
|
|
find_path (LZ4_INCLUDE_DIR NAMES lz4.h PATHS ${LZ4_INCLUDE_PATHS})
|
2017-02-28 23:49:04 +00:00
|
|
|
endif ()
|
|
|
|
|
|
|
|
if (LZ4_LIBRARY AND LZ4_INCLUDE_DIR)
|
2017-04-01 07:20:54 +00:00
|
|
|
include_directories (${LZ4_INCLUDE_DIR})
|
2017-02-28 23:49:04 +00:00
|
|
|
else ()
|
2017-04-01 07:20:54 +00:00
|
|
|
set (USE_INTERNAL_LZ4_LIBRARY 1)
|
|
|
|
set (LZ4_LIBRARY lz4)
|
2017-02-28 23:49:04 +00:00
|
|
|
endif ()
|
|
|
|
|
|
|
|
message (STATUS "Using lz4: ${LZ4_INCLUDE_DIR} : ${LZ4_LIBRARY}")
|