3 %bcond_with tests # build with tests
4 %bcond_without static_libs # don't build static libraries
6 Summary: RocksDB: A Persistent Key-Value Store for Flash and RAM Storage
7 Summary(pl.UTF-8): RocksDB - trwała baza danych klucz-wartość dla pamięci Flash i RAM
13 Source0: https://github.com/facebook/rocksdb/archive/%{name}-%{version}.tar.gz
14 # Source0-md5: 6bdc1defb0a0d8e9e3cb11bfc6e795ef
15 Patch0: %{name}-libdir.patch
16 Patch1: make-programs.patch
17 URL: http://rocksdb.org/
18 BuildRequires: bzip2-devel
19 BuildRequires: gflags-devel
21 BuildRequires: libatomic-devel
23 BuildRequires: libstdc++-devel >= 6:4.7
24 BuildRequires: libtcmalloc-devel
25 BuildRequires: lz4-devel
26 BuildRequires: snappy-devel
27 BuildRequires: zlib-devel
28 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31 RocksDB is a Persistent Key-Value Store for Flash and RAM Storage.
33 %description -l pl.UTF-8
34 RocksDB to trwała baza danych klucz-wartość dla pamięci Flash i RAM.
37 Summary: Header files for RocksDB library
38 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki RocksDB
39 Group: Development/Libraries
40 Requires: %{name} = %{version}-%{release}
41 Requires: libstdc++-devel >= 6:4.7
44 Header files for RocksDB library.
46 %description devel -l pl.UTF-8
47 Pliki nagłówkowe biblioteki RocksDB.
50 Summary: Static RocksDB library
51 Summary(pl.UTF-8): Statyczna biblioteka RocksDB
52 Group: Development/Libraries
53 Requires: %{name}-devel = %{version}-%{release}
56 Static RocksDB library.
58 %description static -l pl.UTF-8
59 Statyczna biblioteka RocksDB.
62 %setup -q -n %{name}-%{name}-%{version}
68 PLATFORM_LDFLAGS="-latomic" \
70 %{__make} shared_lib %{?with_static_libs:static_lib} programs %{?with_tests:check} \
71 AM_DEFAULT_VERBOSITY=1 \
74 OPT="%{rpmcflags} %{!?debug:-DNDEBUG}" \
75 WARNING_FLAGS="%{rpmcppflags} -Wall"
78 rm -rf $RPM_BUILD_ROOT
80 INSTALL_PATH=$RPM_BUILD_ROOT%{_prefix} \
81 INSTALL_LIBDIR=$RPM_BUILD_ROOT%{_libdir} \
84 rm -rf $RPM_BUILD_ROOT
86 %post -p /sbin/ldconfig
87 %postun -p /sbin/ldconfig
90 %defattr(644,root,root,755)
91 %doc HISTORY.md LICENSE PATENTS README.md ROCKSDB_LITE.md
92 %attr(755,root,root) %{_libdir}/librocksdb.so
95 %defattr(644,root,root,755)
97 %{_includedir}/rocksdb
99 %if %{with static_libs}
101 %defattr(644,root,root,755)
102 %{_libdir}/librocksdb.a