]> git.pld-linux.org Git - packages/rocksdb.git/blame_incremental - rocksdb.spec
- updated to 7.8.3 (new soname)
[packages/rocksdb.git] / rocksdb.spec
... / ...
CommitLineData
1# TODO: hdfs/java
2#
3# Conditional build:
4%bcond_with tests # build with tests
5%bcond_with benchmark # enable Google Benchmark
6%bcond_without static_libs # don't build static libraries
7%bcond_without tbb # Threading Building Blocks support
8
9Summary: RocksDB: A Persistent Key-Value Store for Flash and RAM Storage
10Summary(pl.UTF-8): RocksDB - trwała baza danych klucz-wartość dla pamięci Flash i RAM
11Name: rocksdb
12# NOTE: stick to 7.8.x for now; ceph 17.2.5 is not ready for rocksdb 7.10.x (or even 7.9.x?) due to cache changes
13Version: 7.8.3
14Release: 1
15License: BSD
16Group: Libraries
17#Source0Download: https://github.com/facebook/rocksdb/releases
18Source0: https://github.com/facebook/rocksdb/archive/v%{version}/%{name}-%{version}.tar.gz
19# Source0-md5: 745d3b15e57e31670b5ea607c5bb82ff
20Patch0: %{name}-detect-flags.patch
21Patch1: %{name}-pc.patch
22URL: https://rocksdb.org/
23BuildRequires: bzip2-devel >= 1.0.8
24BuildRequires: gflags-devel
25%{?with_benchmark:BuildRequires: google-benchmark-devel}
26# libtcmalloc also supported, but jemalloc is preferred
27BuildRequires: jemalloc-devel
28%ifarch i386 i486
29BuildRequires: libatomic-devel
30%endif
31BuildRequires: libstdc++-devel >= 6:4.7
32BuildRequires: liburing-devel
33BuildRequires: lz4-devel >= 1:1.9.2
34BuildRequires: numactl-devel
35BuildRequires: rpmbuild(macros) >= 1.734
36BuildRequires: snappy-devel >= 1.1.8
37%{?with_tbb:BuildRequires: tbb-devel}
38BuildRequires: zlib-devel >= 1.2.11
39BuildRequires: zstd-devel >= 1.4.4
40Requires: bzip2 >= 1.0.8
41Requires: lz4 >= 1:1.9.2
42Requires: snappy >= 1.1.8
43Requires: zlib >= 1.2.11
44Requires: zstd >= 1.4.4
45BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47%description
48RocksDB is a Persistent Key-Value Store for Flash and RAM Storage.
49
50%description -l pl.UTF-8
51RocksDB to trwała baza danych klucz-wartość dla pamięci Flash i RAM.
52
53%package devel
54Summary: Header files for RocksDB library
55Summary(pl.UTF-8): Pliki nagłówkowe biblioteki RocksDB
56Group: Development/Libraries
57Requires: %{name} = %{version}-%{release}
58Requires: libstdc++-devel >= 6:4.7
59
60%description devel
61Header files for RocksDB library.
62
63%description devel -l pl.UTF-8
64Pliki nagłówkowe biblioteki RocksDB.
65
66%package static
67Summary: Static RocksDB library
68Summary(pl.UTF-8): Statyczna biblioteka RocksDB
69Group: Development/Libraries
70Requires: %{name}-devel = %{version}-%{release}
71
72%description static
73Static RocksDB library.
74
75%description static -l pl.UTF-8
76Statyczna biblioteka RocksDB.
77
78%prep
79%setup -q
80%patch0 -p1
81%patch1 -p1
82
83%build
84%if %{without benchmark}
85export ROCKSDB_DISABLE_BENCHMARK=1
86%endif
87%if %{without tbb}
88export ROCKSDB_DISABLE_TBB=1
89%endif
90
91for target in %{?with_static_libs:static_lib} shared_lib tools_lib tools %{?with_tests:check} ; do
92%ifarch i386 i486
93PLATFORM_LDFLAGS="-latomic" \
94%endif
95%{__make} $target \
96 AM_DEFAULT_VERBOSITY=1 \
97 CC="%{__cc}" \
98 CXX="%{__cxx}" \
99 %{!?with_debug:DEBUG_LEVEL=0} \
100 EXTRA_CFLAGS="$(pkg-config --cflags liblz4)" \
101 OPT="%{rpmcflags} %{!?debug:-DNDEBUG}" \
102 PORTABLE=1 \
103 USE_RTTI=1 \
104 WARNING_FLAGS="%{rpmcppflags} -Wall"
105done
106
107%install
108rm -rf $RPM_BUILD_ROOT
109
110%if %{without benchmark}
111export ROCKSDB_DISABLE_BENCHMARK=1
112%endif
113%if %{without tbb}
114export ROCKSDB_DISABLE_TBB=1
115%endif
116
117%{__make} install \
118 %{!?with_debug:DEBUG_LEVEL=0} \
119 PORTABLE=1 \
120 DESTDIR=$RPM_BUILD_ROOT \
121 PREFIX=%{_prefix} \
122 LIBDIR=%{_libdir}
123
124# reduntant symlink
125%{__rm} $RPM_BUILD_ROOT%{_libdir}/librocksdb.so.7
126
127%clean
128rm -rf $RPM_BUILD_ROOT
129
130%post -p /sbin/ldconfig
131%postun -p /sbin/ldconfig
132
133%files
134%defattr(644,root,root,755)
135%doc AUTHORS DEFAULT_OPTIONS_HISTORY.md DUMP_FORMAT.md HISTORY.md LANGUAGE-BINDINGS.md LICENSE.leveldb README.md ROCKSDB_LITE.md USERS.md
136%attr(755,root,root) %{_libdir}/librocksdb.so.*.*.*
137%attr(755,root,root) %ghost %{_libdir}/librocksdb.so.7.8
138
139%files devel
140%defattr(644,root,root,755)
141%attr(755,root,root) %{_libdir}/librocksdb.so
142%{_includedir}/rocksdb
143%{_pkgconfigdir}/rocksdb.pc
144
145%if %{with static_libs}
146%files static
147%defattr(644,root,root,755)
148%{_libdir}/librocksdb.a
149%endif
This page took 0.092244 seconds and 5 git commands to generate.