]> git.pld-linux.org Git - packages/rocksdb.git/blame - rocksdb.spec
add tests and static_libs bcond. tests fail to compile
[packages/rocksdb.git] / rocksdb.spec
CommitLineData
b427c498
ER
1#
2# Conditional build:
3%bcond_with tests # build with tests
4%bcond_without static_libs # don't build static libraries
5
c4a98ad2
JB
6Summary: RocksDB: A Persistent Key-Value Store for Flash and RAM Storage
7Summary(pl.UTF-8): RocksDB - trwała baza danych klucz-wartość dla pamięci Flash i RAM
8Name: rocksdb
83ab867a 9Version: 3.10.2
c4a98ad2
JB
10Release: 1
11License: BSD
12Group: Libraries
13Source0: https://github.com/facebook/rocksdb/archive/%{name}-%{version}.tar.gz
83ab867a 14# Source0-md5: 6bdc1defb0a0d8e9e3cb11bfc6e795ef
c4a98ad2 15Patch0: %{name}-libdir.patch
b427c498 16Patch1: make-programs.patch
c4a98ad2
JB
17URL: http://rocksdb.org/
18BuildRequires: bzip2-devel
19BuildRequires: gflags-devel
1225ec57
JB
20%ifarch i386 i486
21BuildRequires: libatomic-devel
22%endif
c4a98ad2
JB
23BuildRequires: libstdc++-devel >= 6:4.7
24BuildRequires: libtcmalloc-devel
25BuildRequires: lz4-devel
26BuildRequires: snappy-devel
27BuildRequires: zlib-devel
28BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30%description
31RocksDB is a Persistent Key-Value Store for Flash and RAM Storage.
32
33%description -l pl.UTF-8
34RocksDB to trwała baza danych klucz-wartość dla pamięci Flash i RAM.
35
36%package devel
37Summary: Header files for RocksDB library
38Summary(pl.UTF-8): Pliki nagłówkowe biblioteki RocksDB
39Group: Development/Libraries
40Requires: %{name} = %{version}-%{release}
41Requires: libstdc++-devel >= 6:4.7
42
43%description devel
44Header files for RocksDB library.
45
46%description devel -l pl.UTF-8
47Pliki nagłówkowe biblioteki RocksDB.
48
49%package static
50Summary: Static RocksDB library
51Summary(pl.UTF-8): Statyczna biblioteka RocksDB
52Group: Development/Libraries
53Requires: %{name}-devel = %{version}-%{release}
54
55%description static
56Static RocksDB library.
57
58%description static -l pl.UTF-8
59Statyczna biblioteka RocksDB.
60
61%prep
62%setup -q -n %{name}-%{name}-%{version}
63%patch0 -p1
b427c498 64%patch1 -p1
c4a98ad2
JB
65
66%build
1225ec57
JB
67%ifarch i386 i486
68PLATFORM_LDFLAGS="-latomic" \
69%endif
b427c498 70%{__make} shared_lib %{?with_static_libs:static_lib} programs %{?with_tests:check} \
83ab867a 71 AM_DEFAULT_VERBOSITY=1 \
c4a98ad2
JB
72 CC="%{__cc}" \
73 CXX="%{__cxx}" \
74 OPT="%{rpmcflags} %{!?debug:-DNDEBUG}" \
75 WARNING_FLAGS="%{rpmcppflags} -Wall"
76
77%install
78rm -rf $RPM_BUILD_ROOT
c4a98ad2
JB
79%{__make} install \
80 INSTALL_PATH=$RPM_BUILD_ROOT%{_prefix} \
81 INSTALL_LIBDIR=$RPM_BUILD_ROOT%{_libdir} \
82
83%clean
84rm -rf $RPM_BUILD_ROOT
85
86%post -p /sbin/ldconfig
87%postun -p /sbin/ldconfig
88
89%files
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
93
94%files devel
95%defattr(644,root,root,755)
96%doc doc/*
97%{_includedir}/rocksdb
98
b427c498 99%if %{with static_libs}
c4a98ad2
JB
100%files static
101%defattr(644,root,root,755)
102%{_libdir}/librocksdb.a
b427c498 103%endif
This page took 0.088137 seconds and 4 git commands to generate.