use cmake instead of make

This commit is contained in:
Dmitry Orlov 2021-08-19 00:18:09 +03:00
parent 17c7fa0a56
commit 96fa51e963

View file

@ -14,17 +14,31 @@ src/rocksdb/librocksdb.a:
libzstd.a \
libz.a
make \
-j $(JOBS) \
-e DEBUG_LEVEL=0 \
-e EXTRA_CXXFLAGS="-fPIC" \
-e EXTRA_CFLAGS="-fPIC" \
-e WITH_SNAPPY=1 \
-e WITH_LZ4=1 \
-e WITH_ZLIB=1 \
-e WITH_ZSTD=1 \
-C src/rocksdb \
static_lib
(cd src/rocksdb && mkdir -p build && cd build && cmake \
-DWITH_SNAPPY=1 \
-DWITH_LZ4=1 \
-DWITH_ZLIB=1 \
-DWITH_ZSTD=1 \
-DWITH_GFLAGS=0 \
-DROCKSDB_BUILD_SHARED=0 \
-DWITH_TOOLS=0 \
-DWITH_BENCHMARK_TOOLS=0 \
-DWITH_CORE_TOOLS=0 \
-DWITH_JEMALLOC=0 \
-DCMAKE_BUILD_TYPE=Release \
-DSnappy_INCLUDE_DIRS=../snappy-1.1.8/ \
-DSnappy_LIBRARIES=../snappy-1.1.8/build \
-Dlz4_INCLUDE_DIRS=../lz4-1.9.3/lib \
-Dlz4_LIBRARIES=../lz4-1.9.3/lib \
-Dzstd_INCLUDE_DIRS=../zstd-1.4.9/lib \
-Dzstd_LIBRARIES=../zstd-1.4.9/lib \
-DZLIB_INCLUDE_DIR=../zlib-1.2.11 \
-DZLIB_LIBRARY=./zlib-1.2.11 \
-DCMAKE_CXX_FLAGS="-fPIC -I../snappy-1.1.8/build -I../zstd-1.4.9/lib/dictBuilder" \
.. && make -j $(JOBS))
cp src/rocksdb/build/librocksdb.a src/rocksdb/librocksdb.a
clean:
rm -rf src/rocksdb/build
make -C src/rocksdb clean