Skip to content

Commit

Permalink
fix(rocksdb): specify the HINTS for zstd/lz4/snappy in third-party CM…
Browse files Browse the repository at this point in the history
…akeLists allowing rocksdb to find them (apache#1777)

apache#1788

- put the output library files of zstd/lz4/snappy in the "thirdparty/output/lib"
rather than "thirdparty/output/lib64"
- specify the HINTS for zstd/lz4/snappy in third-party CMakeLists
allowing rocksdb to find them
  • Loading branch information
empiredan authored Dec 19, 2023
1 parent 78256d0 commit e1fce34
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions thirdparty/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,7 @@ ExternalProject_Add(jemalloc

set(SNAPPY_OPTIONS
-DCMAKE_INSTALL_PREFIX=${TP_OUTPUT}
-DCMAKE_INSTALL_LIBDIR=lib
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
-DCMAKE_BUILD_TYPE=Release
-DBUILD_SHARED_LIBS=OFF
Expand Down Expand Up @@ -397,6 +398,7 @@ ExternalProject_Add(zstd
PATCH_COMMAND ""
CONFIGURE_COMMAND cmake build/cmake
-DCMAKE_INSTALL_PREFIX=${TP_OUTPUT}
-DCMAKE_INSTALL_LIBDIR=lib
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
-DCMAKE_BUILD_TYPE=Release
-DZSTD_BUILD_PROGRAMS=OFF
Expand All @@ -418,6 +420,7 @@ ExternalProject_Add(lz4
PATCH_COMMAND ""
CONFIGURE_COMMAND cmake build/cmake
-DCMAKE_INSTALL_PREFIX=${TP_OUTPUT}
-DCMAKE_INSTALL_LIBDIR=lib
-DLZ4_POSITION_INDEPENDENT_LIB=ON
-DCMAKE_BUILD_TYPE=Release
-DLZ4_BUILD_CLI=OFF
Expand All @@ -436,8 +439,11 @@ set(ROCKSDB_OPTIONS
-DWITH_BENCHMARK_TOOLS=OFF
-DWITH_TOOLS=OFF
-DWITH_LZ4=ON
-Dlz4_ROOT_DIR=${TP_OUTPUT}
-DWITH_ZSTD=ON
-Dzstd_ROOT_DIR=${TP_OUTPUT}
-DWITH_SNAPPY=ON
-Dsnappy_ROOT_DIR=${TP_OUTPUT}
-DWITH_BZ2=OFF
-DWITH_TESTS=OFF
-DWITH_GFLAGS=OFF
Expand Down

0 comments on commit e1fce34

Please sign in to comment.