On 02/25/2013 02:53 PM, Wietse Venema wrote:
[snip]
I will evaluate the MDB client once there is a package for a
mainstream LINUX or *BSD distribution that people can install by
typing one or two commands.

(Resend without the (S)RPMs since it exceeded the allowed size)

Hi Wietse,

It seems liblmdb is not yet available in Fedora, RHEL/CentOS. So I just created an RPM for RHEL6/CentOS6. Spec file attached. You can download the x86_64 RPMs & SRPM at http://pjl.home.xs4all.nl/downloads/liblmdb/

Regards,
Patrick
%define gitrev	cbc4664

Name:		liblmdb
Version:	0
Release:	0.1.git%{gitrev}%{?dist}
Summary:	An ultra-fast, ultra-compact key-value data store
Group:		System Environment/Libraries
License:	OpenLDAP
URL:		http://www.openldap.org
# http://www.openldap.org/devel/gitweb.cgi?p=openldap.git;a=shortlog;h=refs/heads/mdb.master
Source0:	openldap-%{gitrev}.tar.gz
BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

%description
The OpenLDAP Lightning Memory-Mapped Database (MDB) MDB is an ultra-fast,
ultra-compact key-value data store developed by Symas for the OpenLDAP Project.
It uses memory-mapped files, so it has the read performance of a pure in-memory
database while still offering the persistence of standard disk-based databases,
and is only limited to the size of the virtual address space, (it is not 
limited to the size of physical RAM). 

%package devel
Summary:	Development files for %{name}
Group:		Development/Libraries
Requires:	%{name} = %{version}-%{release}

%description devel
The %{name}-devel package contains header files for developing
applications that use %{name}.

%prep
%setup -q -n openldap-%{gitrev}

# set prefix
sed -i 's|/usr/local|%{_prefix}|' liblmdb/Makefile

# fix hardcoded lib
sed -i 's|/lib|/%{_lib}|' liblmdb/Makefile

# fix manpage location
sed -i 's|man|share/man|' liblmdb/Makefile

%build
cd liblmdb
make %{?_smp_mflags}
make %{?_smp_mflags} test

%install
rm -rf %{buildroot}
cd liblmdb

# create required directories
mkdir -p %{buildroot}/%{_bindir}
mkdir -p %{buildroot}/%{_libdir}
mkdir -p %{buildroot}/%{_includedir}
mkdir -p %{buildroot}/%{_mandir}/man1

make install DESTDIR=%{buildroot}

%clean
rm -rf %{buildroot}

%post devel
/sbin/ldconfig

%postun devel
/sbin/ldconfig

%files
%defattr(-,root,root,-)
%doc liblmdb/LICENSE liblmdb/COPYRIGHT
%attr(0755,root,root) %{_bindir}/mdb_copy
%attr(0755,root,root) %{_bindir}/mdb_stat
%attr(0644,root,root) %{_mandir}/man1/mdb_copy.1*
%attr(0644,root,root) %{_mandir}/man1/mdb_stat.1*

%files devel
%defattr(-,root,root,-)
%doc liblmdb/LICENSE liblmdb/COPYRIGHT
%attr(0644,root,root) %{_includedir}/lmdb.h
%attr(0755,root,root) %{_libdir}/liblmdb.*

%changelog
* Mon Feb 25 2013 Patrick <patri...@fedoraproject.org> - 0-0.1
- initial spec file for liblmdb


Reply via email to