vcpkg/ports/rocksdb/0005-add-config-to-findpackage.patch

35 lines
875 B
Diff
Raw Normal View History

2020-03-11 08:21:14 +08:00
diff --git a/CMakeLists.txt b/CMakeLists.txt
index eebda35e9..20bafd659 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -98,9 +98,9 @@ else()
endif()
if(WITH_SNAPPY)
- find_package(snappy REQUIRED)
+ find_package(Snappy CONFIG REQUIRED)
add_definitions(-DSNAPPY)
- list(APPEND THIRDPARTY_LIBS snappy::snappy)
+ list(APPEND THIRDPARTY_LIBS Snappy::snappy)
endif()
if(WITH_ZLIB)
@@ -122,7 +122,7 @@ else()
endif()
if(WITH_LZ4)
- find_package(lz4 REQUIRED)
+ find_package(lz4 CONFIG REQUIRED)
add_definitions(-DLZ4)
list(APPEND THIRDPARTY_LIBS lz4::lz4)
endif()
@@ -131,7 +131,7 @@ else()
find_package(zstd REQUIRED)
add_definitions(-DZSTD)
include_directories(${ZSTD_INCLUDE_DIR})
- list(APPEND THIRDPARTY_LIBS zstd::zstd)
+ list(APPEND THIRDPARTY_LIBS ${ZSTD_LIBRARY})
endif()
endif()