ce9f2c4
Name:		leveldb
2b4f7b2
Version:	1.7.0
48f8bb7
Release:	4%{?dist}
ce9f2c4
Summary:	A fast and lightweight key/value database library by Google
ce9f2c4
Group:		Applications/Databases
ce9f2c4
License:	BSD
ce9f2c4
URL:		http://code.google.com/p/leveldb/
ce9f2c4
Source0:	http://leveldb.googlecode.com/files/%{name}-%{version}.tar.gz
ce9f2c4
# Sent upstream - https://code.google.com/p/leveldb/issues/detail?id=101
ce9f2c4
Patch1:		leveldb-0001-Initial-commit-of-the-autotools-stuff.patch
2b4f7b2
# Temporary workaround for secondary arches
2b4f7b2
Patch2:		leveldb-0002-Add-memory-barrier-on-PowerPC.patch
92087ef
# https://groups.google.com/d/topic/leveldb/SbVPvl4j4vU/discussion
2b4f7b2
Patch3:		leveldb-0003-bloom_test-failure-on-big-endian-archs.patch
48f8bb7
# available in https://github.com/fusesource/leveldbjni/blob/leveldbjni-[LEVELDBJNI VERSION]/leveldb.patch
48f8bb7
Patch4:		leveldb-0004-leveldbjni.patch
ce9f2c4
BuildRequires:	snappy-devel
ce9f2c4
BuildRequires:	autoconf
ce9f2c4
BuildRequires:	automake
ce9f2c4
BuildRequires:	libtool
ce9f2c4
ce9f2c4
ce9f2c4
%description
ce9f2c4
LevelDB is a fast key-value storage library written at Google that provides an
ce9f2c4
ordered mapping from string keys to string values.
ce9f2c4
ce9f2c4
ce9f2c4
%package devel
ce9f2c4
Summary: The development files for %{name}
ce9f2c4
Group: Development/Libraries
ce9f2c4
Requires: pkgconfig
ce9f2c4
Requires: %{name}%{?_isa} = %{version}-%{release}
ce9f2c4
Requires: pkgconfig
ce9f2c4
ce9f2c4
ce9f2c4
%description devel
ce9f2c4
Additional header files for development with %{name}.
ce9f2c4
ce9f2c4
ce9f2c4
%prep
ce9f2c4
%setup -q
ce9f2c4
%patch1 -p1
ce9f2c4
%patch2 -p1
92087ef
%patch3 -p1
48f8bb7
%patch4 -p1
ce9f2c4
ce9f2c4
%build
ce9f2c4
autoreconf -ivf
ce9f2c4
%configure --disable-static --with-pic
ce9f2c4
make %{?_smp_mflags}
ce9f2c4
ce9f2c4
ce9f2c4
%install
ce9f2c4
make install DESTDIR=%{buildroot}
ce9f2c4
rm -f %{buildroot}%{_libdir}/*.la
ce9f2c4
ce9f2c4
ce9f2c4
%check
19650f9
%ifarch armv5tel armv7hl
ce9f2c4
# FIXME a couple of tests are failing on these secondary arches
ce9f2c4
make check || true
ce9f2c4
%else
19650f9
# x86, x86_64, ppc, ppc64, ppc64v7 s390, and s390x are fine
ce9f2c4
make check
ce9f2c4
%endif
ce9f2c4
ce9f2c4
ce9f2c4
%post -p /sbin/ldconfig
ce9f2c4
ce9f2c4
ce9f2c4
%postun -p /sbin/ldconfig
ce9f2c4
ce9f2c4
ce9f2c4
%files
ce9f2c4
%doc doc/ AUTHORS LICENSE README
ce9f2c4
%{_libdir}/lib%{name}.so.*
ce9f2c4
ce9f2c4
ce9f2c4
%files devel
ce9f2c4
%{_includedir}/%{name}/
ce9f2c4
%{_libdir}/lib%{name}.so
ce9f2c4
%{_libdir}/pkgconfig/%{name}.pc
ce9f2c4
ce9f2c4
ce9f2c4
%changelog
48f8bb7
* Thu Nov 29 2012 gil cattaneo <puntogil@libero.it> - 1.7.0-4
48f8bb7
- Applied patch for allow leveldbjni build
48f8bb7
19650f9
* Sat Oct 27 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.7.0-3
19650f9
- Dirty workarounds for failed tests on ARM
19650f9
2b4f7b2
* Sat Oct 27 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.7.0-2
2b4f7b2
- Restored patch no.2
2b4f7b2
2b4f7b2
* Sat Oct 27 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.7.0-1
2b4f7b2
- Ver. 1.7.0 (API/ABI compatible bugfix release)
2b4f7b2
92087ef
* Tue Aug 21 2012 Dan HorĂ¡k <dan[at]danny.cz> - 1.5.0-4
92087ef
- add workaround for big endians eg. s390(x)
92087ef
67bf4cc
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.0-3
67bf4cc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
67bf4cc
ce9f2c4
* Wed Jul 11 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.5.0-2
ce9f2c4
- Cleaned up spec by removing EL5-related stuff
ce9f2c4
- Added notes about the patches
ce9f2c4
ce9f2c4
* Fri Jun 15 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.5.0-1
ce9f2c4
- Ver. 1.5.0
ce9f2c4
ce9f2c4
* Thu May 17 2012 Peter Lemenkov <lemenkov@gmail.com> - 1.4.0-1
ce9f2c4
- Initial package