]> git.pld-linux.org Git - packages/rocksdb.git/blame - rocksdb.spec
- use newer rpm macros that skip checking std::__once_callable, std::__once_call
[packages/rocksdb.git] / rocksdb.spec
CommitLineData
d120039a 1# TODO: hdfs/java
b427c498
ER
2#
3# Conditional build:
4%bcond_with tests # build with tests
5%bcond_without static_libs # don't build static libraries
6
c4a98ad2
JB
7Summary: RocksDB: A Persistent Key-Value Store for Flash and RAM Storage
8Summary(pl.UTF-8): RocksDB - trwała baza danych klucz-wartość dla pamięci Flash i RAM
9Name: rocksdb
5aa83c43 10Version: 5.2.1
c4a98ad2
JB
11Release: 1
12License: BSD
13Group: Libraries
d120039a 14#Source0Download: https://github.com/facebook/rocksdb/releases
c4a98ad2 15Source0: https://github.com/facebook/rocksdb/archive/%{name}-%{version}.tar.gz
5aa83c43 16# Source0-md5: 843b4360dbe3d3869c95d3001644dc41
c4a98ad2 17Patch0: %{name}-libdir.patch
b427c498 18Patch1: make-programs.patch
4907cb5a
JB
19Patch2: %{name}-jemalloc.patch
20Patch3: %{name}-detect-flags.patch
c4a98ad2
JB
21URL: http://rocksdb.org/
22BuildRequires: bzip2-devel
23BuildRequires: gflags-devel
d120039a
JB
24# libtcmalloc also supported, but jemalloc is preferred
25BuildRequires: jemalloc-devel
1225ec57
JB
26%ifarch i386 i486
27BuildRequires: libatomic-devel
28%endif
c4a98ad2 29BuildRequires: libstdc++-devel >= 6:4.7
4907cb5a 30BuildRequires: lz4-devel >= 1:1.7
d120039a 31BuildRequires: numactl-devel
dfb5c736 32BuildRequires: rpmbuild(macros) >= 1.734
c4a98ad2
JB
33BuildRequires: snappy-devel
34BuildRequires: zlib-devel
4907cb5a 35BuildRequires: zstd-devel >= 0.8.0
c4a98ad2
JB
36BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37
38%description
39RocksDB is a Persistent Key-Value Store for Flash and RAM Storage.
40
41%description -l pl.UTF-8
42RocksDB to trwała baza danych klucz-wartość dla pamięci Flash i RAM.
43
44%package devel
45Summary: Header files for RocksDB library
46Summary(pl.UTF-8): Pliki nagłówkowe biblioteki RocksDB
47Group: Development/Libraries
48Requires: %{name} = %{version}-%{release}
49Requires: libstdc++-devel >= 6:4.7
50
51%description devel
52Header files for RocksDB library.
53
54%description devel -l pl.UTF-8
55Pliki nagłówkowe biblioteki RocksDB.
56
57%package static
58Summary: Static RocksDB library
59Summary(pl.UTF-8): Statyczna biblioteka RocksDB
60Group: Development/Libraries
61Requires: %{name}-devel = %{version}-%{release}
62
63%description static
64Static RocksDB library.
65
66%description static -l pl.UTF-8
67Statyczna biblioteka RocksDB.
68
69%prep
70%setup -q -n %{name}-%{name}-%{version}
71%patch0 -p1
b427c498 72%patch1 -p1
d120039a 73%patch2 -p1
2592c03f 74%patch3 -p1
c4a98ad2
JB
75
76%build
1225ec57
JB
77%ifarch i386 i486
78PLATFORM_LDFLAGS="-latomic" \
79%endif
b427c498 80%{__make} shared_lib %{?with_static_libs:static_lib} programs %{?with_tests:check} \
83ab867a 81 AM_DEFAULT_VERBOSITY=1 \
c4a98ad2
JB
82 CC="%{__cc}" \
83 CXX="%{__cxx}" \
4907cb5a 84 EXTRA_CFLAGS="$(pkg-config --cflags liblz4)" \
c4a98ad2 85 OPT="%{rpmcflags} %{!?debug:-DNDEBUG}" \
d120039a
JB
86 PORTABLE=1 \
87 %{!?with_debug:DEBUG_LEVEL=0}
c4a98ad2
JB
88 WARNING_FLAGS="%{rpmcppflags} -Wall"
89
90%install
91rm -rf $RPM_BUILD_ROOT
d120039a 92
c4a98ad2 93%{__make} install \
d120039a 94 %{!?with_debug:DEBUG_LEVEL=0} \
c4a98ad2 95 INSTALL_PATH=$RPM_BUILD_ROOT%{_prefix} \
b136638d
JB
96 INSTALL_LIBDIR=$RPM_BUILD_ROOT%{_libdir}
97
98# reduntant symlink
5aa83c43 99%{__rm} $RPM_BUILD_ROOT%{_libdir}/librocksdb.so.5
c4a98ad2
JB
100
101%clean
102rm -rf $RPM_BUILD_ROOT
103
104%post -p /sbin/ldconfig
105%postun -p /sbin/ldconfig
106
107%files
108%defattr(644,root,root,755)
4907cb5a 109%doc AUTHORS DEFAULT_OPTIONS_HISTORY.md DUMP_FORMAT.md HISTORY.md LANGUAGE-BINDINGS.md LICENSE PATENTS README.md ROCKSDB_LITE.md USERS.md
b136638d 110%attr(755,root,root) %{_libdir}/librocksdb.so.*.*.*
5aa83c43 111%attr(755,root,root) %ghost %{_libdir}/librocksdb.so.5.2
c4a98ad2
JB
112
113%files devel
114%defattr(644,root,root,755)
b136638d 115%attr(755,root,root) %{_libdir}/librocksdb.so
c4a98ad2
JB
116%{_includedir}/rocksdb
117
b427c498 118%if %{with static_libs}
c4a98ad2
JB
119%files static
120%defattr(644,root,root,755)
121%{_libdir}/librocksdb.a
b427c498 122%endif
This page took 0.079287 seconds and 4 git commands to generate.