blob: d4f0346ee1ad295a4623f4e0940528607fe4df6e [file] [log] [blame]
Brad Bishop316dfdd2018-06-25 12:45:53 -04001SUMMARY = "RocksDB an embeddable, persistent key-value store"
2DESCRIPTION = "RocksDB is library that provides an embeddable, persistent key-value store for fast storage."
3HOMEPAGE = "http://rocksdb.org/"
Andrew Geissler9aee5002022-03-30 16:27:02 +00004LICENSE = "(Apache-2.0 | GPL-2.0-only) & BSD-3-Clause"
Brad Bishop316dfdd2018-06-25 12:45:53 -04005LIC_FILES_CHKSUM = "file://LICENSE.Apache;md5=3b83ef96387f14655fc854ddc3c6bd57 \
6 file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
7 file://LICENSE.leveldb;md5=fb04ff57a14f308f2eed4a9b87d45837"
8
Andrew Geissler87f5cff2022-09-30 13:13:31 -05009SRCREV = "540d5aae516265170564ec27b3e67a54a11b7045"
10SRCBRANCH = "7.5.fb"
Brad Bishop316dfdd2018-06-25 12:45:53 -040011
Andrew Geissler595f6302022-01-24 19:11:47 +000012SRC_URI = "git://github.com/facebook/${BPN}.git;branch=${SRCBRANCH};protocol=https \
Andrew Geissler82c905d2020-04-13 13:39:40 -050013 file://0001-cmake-Add-check-for-atomic-support.patch \
Andrew Geisslera2681d92020-10-16 10:17:07 -050014 file://0001-cmake-Use-exported-target-for-bz2.patch \
Andrew Geissler69721092021-07-23 12:57:00 -040015 file://ppc64.patch \
16 file://mips.patch \
17 file://arm.patch \
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080018 "
Brad Bishop316dfdd2018-06-25 12:45:53 -040019
Patrick Williams213cb262021-08-07 19:21:33 -050020SRC_URI:append:riscv32 = " file://0001-replace-old-sync-with-new-atomic-builtin-equivalents.patch"
21SRC_URI:append:mips = " file://0001-replace-old-sync-with-new-atomic-builtin-equivalents.patch"
Andrew Geissler9aee5002022-03-30 16:27:02 +000022SRC_URI:append:powerpc = " file://0001-replace-old-sync-with-new-atomic-builtin-equivalents.patch"
Patrick Williams213cb262021-08-07 19:21:33 -050023SRC_URI:remove:toolchain-clang:riscv32 = "file://0001-replace-old-sync-with-new-atomic-builtin-equivalents.patch"
Andrew Geissler69721092021-07-23 12:57:00 -040024
Brad Bishop316dfdd2018-06-25 12:45:53 -040025S = "${WORKDIR}/git"
26
27inherit cmake
28
Brad Bishop15ae2502019-06-18 21:44:24 -040029PACKAGECONFIG ??= "bzip2 zlib lz4 gflags"
Brad Bishope42b3e32020-01-15 22:08:42 -050030PACKAGECONFIG[bzip2] = "-DWITH_BZ2=ON,-DWITH_BZ2=OFF,bzip2"
31PACKAGECONFIG[lz4] = "-DWITH_LZ4=ON,-DWITH_LZ4=OFF,lz4"
32PACKAGECONFIG[zlib] = "-DWITH_ZLIB=ON,-DWITH_ZLIB=OFF,zlib"
Brad Bishop15ae2502019-06-18 21:44:24 -040033PACKAGECONFIG[zstd] = "-DWITH_ZSTD=ON,-DWITH_ZSTD=OFF,zstd"
Brad Bishop316dfdd2018-06-25 12:45:53 -040034PACKAGECONFIG[lite] = "-DROCKSDB_LITE=ON,-DROCKSDB_LITE=OFF"
Brad Bishop15ae2502019-06-18 21:44:24 -040035PACKAGECONFIG[gflags] = "-DWITH_GFLAGS=ON,-DWITH_GFLAGS=OFF,gflags"
Brad Bishop316dfdd2018-06-25 12:45:53 -040036
37# Tools and tests currently don't compile on armv5 so we disable them
38EXTRA_OECMAKE = "\
39 -DPORTABLE=ON \
40 -DWITH_TESTS=OFF \
Andrew Geisslera2681d92020-10-16 10:17:07 -050041 -DWITH_BENCHMARK_TOOLS=OFF \
Brad Bishop316dfdd2018-06-25 12:45:53 -040042 -DWITH_TOOLS=OFF \
Brad Bishope42b3e32020-01-15 22:08:42 -050043 -DFAIL_ON_WARNINGS=OFF \
Brad Bishop316dfdd2018-06-25 12:45:53 -040044"
Brad Bishop19323692019-04-05 15:28:33 -040045
Patrick Williams213cb262021-08-07 19:21:33 -050046do_install:append() {
Brad Bishop19323692019-04-05 15:28:33 -040047 # fix for qa check buildpaths
48 sed -i "s#${RECIPE_SYSROOT}##g" ${D}${libdir}/cmake/rocksdb/RocksDBTargets.cmake
49}
Andrew Geissler82c905d2020-04-13 13:39:40 -050050
Patrick Williams213cb262021-08-07 19:21:33 -050051LDFLAGS:append:riscv64 = " -pthread"
Andrew Geissler9aee5002022-03-30 16:27:02 +000052
53# Need toku_time_now() implemented for ppc/musl
54# see utilities/transactions/lock/range/range_tree/lib/portability/toku_time.h
55COMPATIBLE_HOST:libc-musl:powerpc = "null"