diff options
-rw-r--r-- | meta/cachelib.spec | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/meta/cachelib.spec b/meta/cachelib.spec new file mode 100644 index 0000000..ab0e82a --- /dev/null +++ b/meta/cachelib.spec @@ -0,0 +1,67 @@ +# CacheLib doesn't reliably build with gcc at the moment +%global toolchain clang + +# Likely incompatible with gtest 1.11 +%bcond_with tests + +%global forgeurl https://github.com/facebook/CacheLib +%global commit c9edf4fae2d10b274e082557c4e70523b42be567 +%global date 20211216 +%forgemeta + +Name: cachelib +Version: 0.1 +Release: %autorelease +Summary: Pluggable caching engine for scale high performance cache services + +License: ASL 2.0 +URL: %forgeurl +Source0: %forgesource +# require atomic when building against clang +# will upstream +Patch0: %{name}-req_atomic_for_clang.patch + +BuildRequires: clang +BuildRequires: cmake +BuildRequires: fbthrift-devel +BuildRequires: wangle-devel +BuildRequires: folly-devel +BuildRequires: fizz-devel +BuildRequires: libdwarf-devel +BuildRequires: libzstd-devel +BuildRequires: zlib-devel +BuildRequires: tsl-sparse-map-devel +BuildRequires: libatomic + +%description +CacheLib is a C++ library providing in-process high performance caching +mechanism. CacheLib provides a thread safe API to build high throughput, low +overhead caching services, with built-in ability to leverage DRAM and SSD +caching transparently. + +%prep +%forgeautosetup -p1 + +%build +pushd cachelib +%if %{with tests} +%cmake +%else +%cmake -DBUILD_TESTS:BOOL=OFF +%endif +%cmake_build + +%check +pushd cachelib +%ctest + +%install +pushd cachelib +%cmake_install + +%files +%license LICENSE +%doc BENCHMARKS.md CHANGELOG.md README.md examples + +%changelog +%autochangelog |