File automake.diff of Package lmdb

From: Jan Engelhardt <>
Date: 2014-05-16 21:40:05.570658956 +0200
Upstream: Submitted and rejected

build: use automake for building

The upstream Makefile suffers from some shortcomings, such as:
 - Provides no way to set bindir, libdir, docdir/mandir.
 - Fails to mkdir the DESTDIR tree on make install.
 - Uses the wrong shared library extension on MinGW/Cygwin.
 - No way of turning off static library generation at build time.
 - There is no shared library versioning of any kind, which does not line up
   with the guidelines for openSUSE and other distributions.
   Upstream believes it will never change anything in an incompatible way.
   While I, the patch author, concur with that expectation, it does not solve
   the issue with compatible changes (such as adding functions), for which
   symbol version maps would come into play. As I do not want to also maintain
   a symvers patch, I will apply the naming guidelines of section
   meaning the use of -release ${PACKAGE_VERSION}.

LMDB is a very simple project without many source files or compile-time flag
combinations; working with the original Makefile does not need all that many
hoops. But it is a tie IMO, and so, the casting vote shall be the AM route.
---  |   16 ++++++++++++++++ |   13 +++++++++++++
 2 files changed, 29 insertions(+)

--- /dev/null
+++ liblmdb/
@@ -0,0 +1,17 @@
+# -*- Makefile -*-
+AM_CFLAGS = -W -Wall -Wno-unused-parameter -Wbad-function-cast -pthread
+AM_CPPFLAGS = -include config.h
+bin_PROGRAMS = mdb_copy mdb_stat
+check_PROGRAMS = mtest mtest2 mtest3 mtest4 mtest5
+man_MANS = mdb_copy.1 mdb_stat.1
+include_HEADERS = lmdb.h
+liblmdb_la_SOURCES = mdb.c midl.c
+liblmdb_la_LDFLAGS = -release ${PACKAGE_VERSION}
+	rm -Rf testdb
--- /dev/null
+++ liblmdb/
@@ -0,0 +1,15 @@
+AC_INIT([liblmdb], [0.9.11], [])
+AM_INIT_AUTOMAKE([-Wall foreign subdir-objects tar-pax])
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
+m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
openSUSE Build Service is sponsored by