summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.bzrignore1
-rw-r--r--ChangeLog3
-rw-r--r--GNUmakefile2
-rw-r--r--Makefile.am21
-rwxr-xr-xbootstrap.sh45
-rw-r--r--configure.ac9
-rw-r--r--docs/Makefile200
-rw-r--r--docs/include.am.THIS (renamed from docs/include.am)0
-rw-r--r--docs/source/bin/memaslap.rst (renamed from docs/bin/memaslap.rst)0
-rw-r--r--docs/source/bin/memcapable.rst (renamed from docs/bin/memcapable.rst)0
-rw-r--r--docs/source/bin/memcat.rst (renamed from docs/bin/memcat.rst)0
-rw-r--r--docs/source/bin/memcp.rst (renamed from docs/bin/memcp.rst)0
-rw-r--r--docs/source/bin/memdump.rst (renamed from docs/bin/memdump.rst)0
-rw-r--r--docs/source/bin/memerror.rst (renamed from docs/bin/memerror.rst)0
-rw-r--r--docs/source/bin/memexist.rst (renamed from docs/bin/memexist.rst)0
-rw-r--r--docs/source/bin/memflush.rst (renamed from docs/bin/memflush.rst)0
-rw-r--r--docs/source/bin/memparse.rst (renamed from docs/bin/memparse.rst)0
-rw-r--r--docs/source/bin/memping.rst (renamed from docs/bin/memping.rst)0
-rw-r--r--docs/source/bin/memrm.rst (renamed from docs/bin/memrm.rst)0
-rw-r--r--docs/source/bin/memslap.rst (renamed from docs/bin/memslap.rst)0
-rw-r--r--docs/source/bin/memstat.rst (renamed from docs/bin/memstat.rst)0
-rw-r--r--docs/source/bin/memtouch.rst (renamed from docs/bin/memtouch.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_AUTH_CONTINUE.rst (renamed from docs/client_errors/MEMCACHED_AUTH_CONTINUE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_AUTH_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_AUTH_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_AUTH_PROBLEM.rst (renamed from docs/client_errors/MEMCACHED_AUTH_PROBLEM.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst (renamed from docs/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_BUFFERED.rst (renamed from docs/client_errors/MEMCACHED_BUFFERED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_CLIENT_ERROR.rst (renamed from docs/client_errors/MEMCACHED_CLIENT_ERROR.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_CONNECTION_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_CONNECTION_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst (renamed from docs/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_DATA_EXISTS.rst (renamed from docs/client_errors/MEMCACHED_DATA_EXISTS.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_DELETED.rst (renamed from docs/client_errors/MEMCACHED_DELETED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_DEPRECATED.rst (renamed from docs/client_errors/MEMCACHED_DEPRECATED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_E2BIG.rst (renamed from docs/client_errors/MEMCACHED_E2BIG.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_END.rst (renamed from docs/client_errors/MEMCACHED_END.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_ERRNO.rst (renamed from docs/client_errors/MEMCACHED_ERRNO.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst (renamed from docs/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst (renamed from docs/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst (renamed from docs/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst (renamed from docs/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_ITEM.rst (renamed from docs/client_errors/MEMCACHED_ITEM.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_KEY_TOO_BIG.rst (renamed from docs/client_errors/MEMCACHED_KEY_TOO_BIG.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_MAXIMUM_RETURN.rst (renamed from docs/client_errors/MEMCACHED_MAXIMUM_RETURN.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_NOTFOUND.rst (renamed from docs/client_errors/MEMCACHED_NOTFOUND.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_NOTSTORED.rst (renamed from docs/client_errors/MEMCACHED_NOTSTORED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_NOT_SUPPORTED.rst (renamed from docs/client_errors/MEMCACHED_NOT_SUPPORTED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst (renamed from docs/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_NO_SERVERS.rst (renamed from docs/client_errors/MEMCACHED_NO_SERVERS.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_PARSE_ERROR.rst (renamed from docs/client_errors/MEMCACHED_PARSE_ERROR.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_PARSE_USER_ERROR.rst (renamed from docs/client_errors/MEMCACHED_PARSE_USER_ERROR.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_PARTIAL_READ.rst (renamed from docs/client_errors/MEMCACHED_PARTIAL_READ.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_PROTOCOL_ERROR.rst (renamed from docs/client_errors/MEMCACHED_PROTOCOL_ERROR.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_READ_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_READ_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_SERVER_ERROR.rst (renamed from docs/client_errors/MEMCACHED_SERVER_ERROR.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst (renamed from docs/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_SOME_ERRORS.rst (renamed from docs/client_errors/MEMCACHED_SOME_ERRORS.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_STAT.rst (renamed from docs/client_errors/MEMCACHED_STAT.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_STORED.rst (renamed from docs/client_errors/MEMCACHED_STORED.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_SUCCESS.rst (renamed from docs/client_errors/MEMCACHED_SUCCESS.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_TIMEOUT.rst (renamed from docs/client_errors/MEMCACHED_TIMEOUT.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst (renamed from docs/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_VALUE.rst (renamed from docs/client_errors/MEMCACHED_VALUE.rst)0
-rw-r--r--docs/source/client_errors/MEMCACHED_WRITE_FAILURE.rst (renamed from docs/client_errors/MEMCACHED_WRITE_FAILURE.rst)0
-rw-r--r--docs/source/conf.py.in (renamed from docs/conf.py.in)0
-rw-r--r--docs/source/error_messages.rst (renamed from docs/error_messages.rst)0
-rw-r--r--docs/source/hashkit_create.rst (renamed from docs/hashkit_create.rst)0
-rw-r--r--docs/source/hashkit_functions.rst (renamed from docs/hashkit_functions.rst)0
-rw-r--r--docs/source/hashkit_value.rst (renamed from docs/hashkit_value.rst)0
-rw-r--r--docs/source/index.rst (renamed from docs/index.rst)0
-rw-r--r--docs/source/libhashkit.rst (renamed from docs/libhashkit.rst)0
-rw-r--r--docs/source/libmemcached-1.0/index.rst (renamed from docs/libmemcached-1.0/index.rst)0
-rw-r--r--docs/source/libmemcached-1.0/memcached_set_encoding_key.rst (renamed from docs/libmemcached-1.0/memcached_set_encoding_key.rst)0
-rw-r--r--docs/source/libmemcached-1.0/memcached_touch.rst (renamed from docs/libmemcached-1.0/memcached_touch.rst)0
-rw-r--r--docs/source/libmemcached-1.1/index.rst (renamed from docs/libmemcached-1.1/index.rst)0
-rw-r--r--docs/source/libmemcached.rst (renamed from docs/libmemcached.rst)0
-rw-r--r--docs/source/libmemcached/defaults.rst (renamed from docs/libmemcached/defaults.rst)0
-rw-r--r--docs/source/libmemcached/memcached_exist.rst (renamed from docs/libmemcached/memcached_exist.rst)0
-rw-r--r--docs/source/libmemcached/memcached_fetch.rst (renamed from docs/libmemcached/memcached_fetch.rst)0
-rw-r--r--docs/source/libmemcached/memcached_last_error_message.rst (renamed from docs/libmemcached/memcached_last_error_message.rst)0
-rw-r--r--docs/source/libmemcached/memcached_return_t.rst (renamed from docs/libmemcached/memcached_return_t.rst)0
-rw-r--r--docs/source/libmemcached_configuration.rst (renamed from docs/libmemcached_configuration.rst)0
-rw-r--r--docs/source/libmemcached_examples.rst (renamed from docs/libmemcached_examples.rst)0
-rw-r--r--docs/source/libmemcachedutil.rst (renamed from docs/libmemcachedutil.rst)0
-rw-r--r--docs/source/memcached_analyze.rst (renamed from docs/memcached_analyze.rst)0
-rw-r--r--docs/source/memcached_append.rst (renamed from docs/memcached_append.rst)0
-rw-r--r--docs/source/memcached_auto.rst (renamed from docs/memcached_auto.rst)0
-rw-r--r--docs/source/memcached_behavior.rst (renamed from docs/memcached_behavior.rst)0
-rw-r--r--docs/source/memcached_callback.rst (renamed from docs/memcached_callback.rst)0
-rw-r--r--docs/source/memcached_cas.rst (renamed from docs/memcached_cas.rst)0
-rw-r--r--docs/source/memcached_create.rst (renamed from docs/memcached_create.rst)0
-rw-r--r--docs/source/memcached_delete.rst (renamed from docs/memcached_delete.rst)0
-rw-r--r--docs/source/memcached_dump.rst (renamed from docs/memcached_dump.rst)0
-rw-r--r--docs/source/memcached_flush.rst (renamed from docs/memcached_flush.rst)0
-rw-r--r--docs/source/memcached_flush_buffers.rst (renamed from docs/memcached_flush_buffers.rst)0
-rw-r--r--docs/source/memcached_generate_hash_value.rst (renamed from docs/memcached_generate_hash_value.rst)0
-rw-r--r--docs/source/memcached_get.rst (renamed from docs/memcached_get.rst)0
-rw-r--r--docs/source/memcached_memory_allocators.rst (renamed from docs/memcached_memory_allocators.rst)0
-rw-r--r--docs/source/memcached_pool.rst (renamed from docs/memcached_pool.rst)0
-rw-r--r--docs/source/memcached_quit.rst (renamed from docs/memcached_quit.rst)0
-rw-r--r--docs/source/memcached_result_st.rst (renamed from docs/memcached_result_st.rst)0
-rw-r--r--docs/source/memcached_sasl.rst (renamed from docs/memcached_sasl.rst)0
-rw-r--r--docs/source/memcached_server_st.rst (renamed from docs/memcached_server_st.rst)0
-rw-r--r--docs/source/memcached_servers.rst (renamed from docs/memcached_servers.rst)0
-rw-r--r--docs/source/memcached_set.rst (renamed from docs/memcached_set.rst)0
-rw-r--r--docs/source/memcached_stats.rst (renamed from docs/memcached_stats.rst)0
-rw-r--r--docs/source/memcached_strerror.rst (renamed from docs/memcached_strerror.rst)0
-rw-r--r--docs/source/memcached_user_data.rst (renamed from docs/memcached_user_data.rst)0
-rw-r--r--docs/source/memcached_verbosity.rst (renamed from docs/memcached_verbosity.rst)0
-rw-r--r--docs/source/memcached_version.rst (renamed from docs/memcached_version.rst)0
-rw-r--r--docs/source/tap.rst (renamed from docs/tap.rst)0
-rw-r--r--docs/source/types.rst (renamed from docs/types.rst)0
-rw-r--r--docs/source/versioning.rst (renamed from docs/versioning.rst)0
-rw-r--r--libtest/include.am4
-rw-r--r--man/include.am8
-rw-r--r--rpm/include.am36
-rw-r--r--rpm/include.mk55
-rw-r--r--support/libmemcached.spec.in2
123 files changed, 302 insertions, 84 deletions
diff --git a/.bzrignore b/.bzrignore
index 28c48a4f..8adb8969 100644
--- a/.bzrignore
+++ b/.bzrignore
@@ -32,6 +32,7 @@ Makefile.in
TAGS
aclocal.m4
aminclude.am
+artifacts
autom4te.cache
autoscan.log
build-aux/
diff --git a/ChangeLog b/ChangeLog
index 098c559a..db8053ef 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,8 +1,9 @@
1.1.0
* Enable MEMCACHED_BEHAVIOR_VERIFY_KEY by default
-1.0.18
+1.0.18 Sun Feb 9 01:49:56 PST 2014
* MEMCACHED_BEHAVIOR_RETRY_TIMEOUT can now be set to zero.
+* Numerous bug fixes.
1.0.17 Tue Apr 2 14:02:01 HST 2013
* Remove c++ namespace that was being exposed (the API should be plug compatible)..
diff --git a/GNUmakefile b/GNUmakefile
index 33ec5acc..b105d013 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -1,4 +1,4 @@
-# -*-Makefile-*-
+# vim:ft=make
#
_bootstrap_Makefile := $(wildcard [M]akefile)
_bootstrap_config-status := $(wildcard config.status)
diff --git a/Makefile.am b/Makefile.am
index b7c99a5e..0ffea520 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -26,6 +26,10 @@ EXTRA_DIST=
dist_man_MANS=
MAINTAINERCLEANFILES=
+if IS_VCS_CHECKOUT
+SUBDIRS= docs
+endif
+
#includes additional rules from aminclude.am
@INC_AMINCLUDE@
@@ -52,14 +56,14 @@ include libmemcached-1.2/include.am
include libmemcachedutil-1.2/include.am
include clients/include.am
-include docs/include.am
+
include man/include.am
include libhashkit/include.am
include libmemcached/include.am
include libmemcachedutil/include.am
include libmemcachedinternal/include.am
include libmemcachedinternal/util/include.am
-include rpm/include.am
+include rpm/include.mk
include support/include.am
include tests/include.am
include util/include.am
@@ -81,7 +85,6 @@ merge-clean:
@find ./ | $(GREP) \.moved | xargs rm -r -f
@find ./ | $(GREP) \\.orig | xargs rm -f
@find ./ | $(GREP) \.rej | xargs rm -f
- @rm -f *\.rpm
@find ./ | $(GREP) \.THIS | xargs rm -f
@find ./ | $(GREP) \.OTHER | xargs rm -f
@find ./ | $(GREP) \.BASE | xargs rm -f
@@ -89,7 +92,7 @@ merge-clean:
@echo "Files that need to be either removed or checked in:"
@bzr unknowns
-clean-local: clean-libtest-check clean-docs-check
+clean-local: clean-libtest-check clean-rpm
lcov: lcov-clean check
@@ -111,12 +114,7 @@ DISTCLEANFILES+= config/top.h
maintainer-clean-local:
find . -type f -name '*~' -exec rm -f '{}' \;
- -rm -f @PACKAGE@-*.rpm
- -rm -f @PACKAGE@-*.tar.gz
- -rm -f man/*.1
- -rm -f man/*.3
- -rm -f man/*.8
- -rm -rf man/.doctrees/
+ -$(RM) $(dist_man_MANS)
-rm -f Makefile.in
-rm -f aclocal.m4
-rm -f build-aux/compile
@@ -126,6 +124,7 @@ maintainer-clean-local:
-rm -f build-aux/install-sh
-rm -f build-aux/ltmain.sh
-rm -f build-aux/missing
+ -rm -f build-aux/test-driver
-rm -f build-aux/ylwrap
-rm -f mem_config.in
-rm -f config.log
@@ -139,4 +138,4 @@ maintainer-clean-local:
-rm -f m4/test-driver
-rmdir build-aux
-rm -rf ${top_builddir}/html
- -rm -f bootstrap
+ -rm -f $(DIST_ARCHIVES)
diff --git a/bootstrap.sh b/bootstrap.sh
index d45c9194..0383c8fa 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -1010,14 +1010,16 @@ make_rpm ()
{
if command_exists 'rpmbuild'; then
if [ -f 'rpm.am' -o -d 'rpm' ]; then
- mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
- mkdir -p ~/rpmbuild/RPMS/{i386,i486,i586,i686,noarch,athlon}
-
run_configure_if_required
- make_target 'rpm'
+ make_target 'dist-rpm'
if $jenkins_build_environment; then
- make_target 'clean'
+ mkdir artifacts
+ mv *.tar.gz *.rpm artifacts
+
+ make_target 'maintainer-clean'
+ mv artifacts/* .
+ rmdir artifacts
fi
fi
@@ -1098,7 +1100,11 @@ run_autoreconf ()
if $use_libtool; then
assert $BOOTSTRAP_LIBTOOLIZE
- run "$BOOTSTRAP_LIBTOOLIZE" '--copy' '--install' '--force' || die "Cannot execute $BOOTSTRAP_LIBTOOLIZE"
+ if $jenkins_build_environment; then
+ run "$BOOTSTRAP_LIBTOOLIZE" '--copy' '--install' || die "Cannot execute $BOOTSTRAP_LIBTOOLIZE"
+ else
+ run "$BOOTSTRAP_LIBTOOLIZE" '--copy' '--install' '--force' || die "Cannot execute $BOOTSTRAP_LIBTOOLIZE"
+ fi
fi
run "$AUTORECONF" "$AUTORECONF_ARGS" || die "Cannot execute $AUTORECONF"
@@ -1239,7 +1245,11 @@ autoreconf_setup ()
fi
if [[ -z "$GNU_BUILD_FLAGS" ]]; then
- GNU_BUILD_FLAGS="--install --force"
+ if $jenkins_build_environment; then
+ GNU_BUILD_FLAGS="--install"
+ else
+ GNU_BUILD_FLAGS="--install --force"
+ fi
fi
if $verbose; then
@@ -1557,7 +1567,8 @@ execute_job ()
check_make_target $target
ret=$?
if [ $ret -ne 0 ]; then
- die "Unknown BOOTSTRAP_TARGET option: $target"
+ warn "Unknown BOOTSTRAP_TARGET option: $target"
+ target="jenkins"
fi
fi
@@ -1732,24 +1743,6 @@ main ()
BOOTSTRAP_TARGET="$OPT_TARGET"
fi
- # If we are running under Jenkins we predetermine what tests we will run against
- # This BOOTSTRAP_TARGET can be overridden by parse_command_line_options based BOOTSTRAP_TARGET changes.
- # We don't want Jenkins overriding other variables, so we NULL them.
- if [ -z "$BOOTSTRAP_TARGET" ]; then
- if $jenkins_build_environment; then
- if [[ -n "$JENKINS_TARGET" ]]; then
- check_make_target $JENKINS_TARGET
- if [ $? -eq 0 ]; then
- BOOTSTRAP_TARGET="$JENKINS_TARGET"
- else
- die "label not found: $label"
- fi
- else
- BOOTSTRAP_TARGET='jenkins'
- fi
- fi
- fi
-
if [ -z "$BOOTSTRAP_TARGET" ]; then
BOOTSTRAP_TARGET="make_default"
fi
diff --git a/configure.ac b/configure.ac
index f8d0ff97..3cc393fc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,3 +1,5 @@
+# configure.ac -*- autoconf -*- vim: filetype=config
+#
# LibmemcacheD
# Copyright (C) 2011-2013 Data Differential, http://datadifferential.com/
# Copyright (C) 2006-2010 Brian Aker, Monty Taylor, Trond Norbye
@@ -7,6 +9,7 @@
# the COPYING file in this directory for full text.
m4_include([version.m4])
+
AC_PREREQ([2.61])
AC_INIT([libmemcached],VERSION_NUMBER,[http://libmemcached.org/])
@@ -47,6 +50,7 @@ AC_SUBST([MEMCACHED_LIBRARY_VERSION])
AX_HEX_VERSION([LIBMEMCACHED],[$VERSION])
AX_HEX_VERSION([LIBHASHKIT],[1.0.0])
+AC_SUBST([RPM_RELEASE],[1])
m4_include([libhashkit/include.m4])
@@ -121,6 +125,9 @@ AC_CHECK_PROGS([PERL],[perl])
AC_CHECK_PROGS([VALGRIND],['valgrind'])
AC_CHECK_PROGS([WINE],['wine'])
AC_CHECK_PROGS([YACC],['bison --warnings=all'],[:])
+AC_CHECK_PROGS([RPMBUILD],[rpmbuild --nocheck])
+AC_CHECK_PROGS([RPMDEV_SETUPTREE],[rpmdev-setuptree])
+AC_CHECK_PROGS([RPM],[rpm])
AC_PROG_AWK
AC_PROG_MKDIR_P
AC_PROG_SED
@@ -329,7 +336,7 @@ AX_HARDEN_COMPILER_FLAGS
AX_AM_JOBSERVER([yes])
AC_CONFIG_FILES([Makefile
- docs/conf.py
+ docs/source/conf.py
libmemcached-1.2/configure.h
support/libmemcached.pc
support/libmemcached.spec
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100644
index 00000000..9ce1fa72
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,200 @@
+# Makefile for Sphinx documentation
+
+# You can set these variables from the command line.
+SPHINXOPTS =
+SPHINXBUILD = sphinx-build
+PAPER =
+BUILDDIR = build
+
+# Custom rules used by top level make
+MANGOAL:= $(BUILDDIR)/man/.dirstamp
+HTMLGOAL:= $(BUILDDIR)/html/.dirstamp
+
+.PHONY: all distclean distcheck maintainer-clean check test
+all: $(MANGOAL) $(HTMLGOAL)
+
+maintainer-clean distclean: clean
+
+distcheck check distdir:
+
+RST_FILES= $(shell find source -type f -name '*.rst')
+
+.DEFAULT_GOAL:= all
+
+.NOTPARALLEL:
+
+SOURCES=
+SOURCES+= $(RST_FILES)
+SOURCES+= source/conf.py
+SOURCES+= Makefile
+
+$(MANGOAL): $(SOURCES)
+ @$(MAKE) $(AM_MAKEFLAGS) man
+ @touch $@
+
+$(HTMLGOAL): $(SOURCES)
+ @$(MAKE) $(AM_MAKEFLAGS) html
+ @touch $@
+
+# User-friendly check for sphinx-build
+ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1)
+$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/)
+endif
+
+# Internal variables.
+PAPEROPT_a4 = -D latex_paper_size=a4
+PAPEROPT_letter = -D latex_paper_size=letter
+ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
+# the i18n builder cannot share the environment and doctrees with the others
+I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
+
+.PHONY: help clean dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text changes linkcheck doctest gettext
+
+help:
+ @echo "Please use \`make <target>' where <target> is one of"
+ @echo " html to make standalone HTML files"
+ @echo " dirhtml to make HTML files named index.html in directories"
+ @echo " singlehtml to make a single large HTML file"
+ @echo " pickle to make pickle files"
+ @echo " json to make JSON files"
+ @echo " htmlhelp to make HTML files and a HTML help project"
+ @echo " qthelp to make HTML files and a qthelp project"
+ @echo " devhelp to make HTML files and a Devhelp project"
+ @echo " epub to make an epub"
+ @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
+ @echo " latexpdf to make LaTeX files and run them through pdflatex"
+ @echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx"
+ @echo " text to make text files"
+ @echo " man to make manual pages"
+ @echo " texinfo to make Texinfo files"
+ @echo " info to make Texinfo files and run them through makeinfo"
+ @echo " gettext to make PO message catalogs"
+ @echo " changes to make an overview of all changed/added/deprecated items"
+ @echo " xml to make Docutils-native XML files"
+ @echo " pseudoxml to make pseudoxml-XML files for display purposes"
+ @echo " linkcheck to check all external links for integrity"
+ @echo " doctest to run all doctests embedded in the documentation (if enabled)"
+
+clean:
+ @$(RM) -r $(BUILDDIR)/*
+
+html: $(SOURCES)
+ $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
+
+dirhtml:
+ $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
+ @echo
+ @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
+
+singlehtml:
+ $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
+ @echo
+ @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
+
+pickle:
+ $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
+
+json:
+ $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
+ @echo
+ @echo "Build finished; now you can process the JSON files."
+
+htmlhelp:
+ $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
+ @echo
+ @echo "Build finished; now you can run HTML Help Workshop with the" \
+ ".hhp project file in $(BUILDDIR)/htmlhelp."
+
+qthelp:
+ $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
+ @echo
+ @echo "Build finished; now you can run "qcollectiongenerator" with the" \
+ ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
+ @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/gearmand.qhcp"
+ @echo "To view the help file:"
+ @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/gearmand.qhc"
+
+devhelp:
+ $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
+ @echo
+ @echo "Build finished."
+ @echo "To view the help file:"
+ @echo "# mkdir -p $$HOME/.local/share/devhelp/gearmand"
+ @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/gearmand"
+ @echo "# devhelp"
+
+epub:
+ $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
+ @echo
+ @echo "Build finished. The epub file is in $(BUILDDIR)/epub."
+
+latex:
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+ @echo
+ @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
+ @echo "Run \`make' in that directory to run these through (pdf)latex" \
+ "(use \`make latexpdf' here to do that automatically)."
+
+latexpdf:
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+ @echo "Running LaTeX files through pdflatex..."
+ $(MAKE) -C $(BUILDDIR)/latex all-pdf
+ @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
+
+latexpdfja:
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+ @echo "Running LaTeX files through platex and dvipdfmx..."
+ $(MAKE) -C $(BUILDDIR)/latex all-pdf-ja
+ @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
+
+text:
+ $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
+ @echo
+ @echo "Build finished. The text files are in $(BUILDDIR)/text."
+
+man: $(SOURCES)
+ $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
+
+texinfo:
+ $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
+ @echo
+ @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
+ @echo "Run \`make' in that directory to run these through makeinfo" \
+ "(use \`make info' here to do that automatically)."
+
+info:
+ $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
+ @echo "Running Texinfo files through makeinfo..."
+ make -C $(BUILDDIR)/texinfo info
+ @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."
+
+gettext:
+ $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale
+ @echo
+ @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."
+
+changes:
+ $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
+ @echo
+ @echo "The overview file is in $(BUILDDIR)/changes."
+
+linkcheck:
+ $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
+ @echo
+ @echo "Link check complete; look for any errors in the above output " \
+ "or in $(BUILDDIR)/linkcheck/output.txt."
+
+doctest:
+ @$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
+ @echo "Testing of doctests in the sources finished, look at the " \
+ "results in $(BUILDDIR)/doctest/output.txt."
+
+xml:
+ $(SPHINXBUILD) -b xml $(ALLSPHINXOPTS) $(BUILDDIR)/xml
+ @echo
+ @echo "Build finished. The XML files are in $(BUILDDIR)/xml."
+
+pseudoxml:
+ $(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml
+ @echo
+ @echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml."
diff --git a/docs/include.am b/docs/include.am.THIS
index 7b6095b1..7b6095b1 100644
--- a/docs/include.am
+++ b/docs/include.am.THIS
diff --git a/docs/bin/memaslap.rst b/docs/source/bin/memaslap.rst
index 61060675..61060675 100644
--- a/docs/bin/memaslap.rst
+++ b/docs/source/bin/memaslap.rst
diff --git a/docs/bin/memcapable.rst b/docs/source/bin/memcapable.rst
index 0e4f33e3..0e4f33e3 100644
--- a/docs/bin/memcapable.rst
+++ b/docs/source/bin/memcapable.rst
diff --git a/docs/bin/memcat.rst b/docs/source/bin/memcat.rst
index b8612a92..b8612a92 100644
--- a/docs/bin/memcat.rst
+++ b/docs/source/bin/memcat.rst
diff --git a/docs/bin/memcp.rst b/docs/source/bin/memcp.rst
index a85eed8b..a85eed8b 100644
--- a/docs/bin/memcp.rst
+++ b/docs/source/bin/memcp.rst
diff --git a/docs/bin/memdump.rst b/docs/source/bin/memdump.rst
index 6a8e12da..6a8e12da 100644
--- a/docs/bin/memdump.rst
+++ b/docs/source/bin/memdump.rst
diff --git a/docs/bin/memerror.rst b/docs/source/bin/memerror.rst
index 53fc09c4..53fc09c4 100644
--- a/docs/bin/memerror.rst
+++ b/docs/source/bin/memerror.rst
diff --git a/docs/bin/memexist.rst b/docs/source/bin/memexist.rst
index 22c3a4d8..22c3a4d8 100644
--- a/docs/bin/memexist.rst
+++ b/docs/source/bin/memexist.rst
diff --git a/docs/bin/memflush.rst b/docs/source/bin/memflush.rst
index a2b9894d..a2b9894d 100644
--- a/docs/bin/memflush.rst
+++ b/docs/source/bin/memflush.rst
diff --git a/docs/bin/memparse.rst b/docs/source/bin/memparse.rst
index c50c5f02..c50c5f02 100644
--- a/docs/bin/memparse.rst
+++ b/docs/source/bin/memparse.rst
diff --git a/docs/bin/memping.rst b/docs/source/bin/memping.rst
index 5a784299..5a784299 100644
--- a/docs/bin/memping.rst
+++ b/docs/source/bin/memping.rst
diff --git a/docs/bin/memrm.rst b/docs/source/bin/memrm.rst
index d395b364..d395b364 100644
--- a/docs/bin/memrm.rst
+++ b/docs/source/bin/memrm.rst
diff --git a/docs/bin/memslap.rst b/docs/source/bin/memslap.rst
index fbaa5fe3..fbaa5fe3 100644
--- a/docs/bin/memslap.rst
+++ b/docs/source/bin/memslap.rst
diff --git a/docs/bin/memstat.rst b/docs/source/bin/memstat.rst
index 9b60297d..9b60297d 100644
--- a/docs/bin/memstat.rst
+++ b/docs/source/bin/memstat.rst
diff --git a/docs/bin/memtouch.rst b/docs/source/bin/memtouch.rst
index 3f7cd1c7..3f7cd1c7 100644
--- a/docs/bin/memtouch.rst
+++ b/docs/source/bin/memtouch.rst
diff --git a/docs/client_errors/MEMCACHED_AUTH_CONTINUE.rst b/docs/source/client_errors/MEMCACHED_AUTH_CONTINUE.rst
index e410592c..e410592c 100644
--- a/docs/client_errors/MEMCACHED_AUTH_CONTINUE.rst
+++ b/docs/source/client_errors/MEMCACHED_AUTH_CONTINUE.rst
diff --git a/docs/client_errors/MEMCACHED_AUTH_FAILURE.rst b/docs/source/client_errors/MEMCACHED_AUTH_FAILURE.rst
index 9433eb88..9433eb88 100644
--- a/docs/client_errors/MEMCACHED_AUTH_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_AUTH_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_AUTH_PROBLEM.rst b/docs/source/client_errors/MEMCACHED_AUTH_PROBLEM.rst
index ba8f22ca..ba8f22ca 100644
--- a/docs/client_errors/MEMCACHED_AUTH_PROBLEM.rst
+++ b/docs/source/client_errors/MEMCACHED_AUTH_PROBLEM.rst
diff --git a/docs/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst b/docs/source/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst
index da1c0b8d..da1c0b8d 100644
--- a/docs/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst
+++ b/docs/source/client_errors/MEMCACHED_BAD_KEY_PROVIDED.rst
diff --git a/docs/client_errors/MEMCACHED_BUFFERED.rst b/docs/source/client_errors/MEMCACHED_BUFFERED.rst
index 027d0ced..027d0ced 100644
--- a/docs/client_errors/MEMCACHED_BUFFERED.rst
+++ b/docs/source/client_errors/MEMCACHED_BUFFERED.rst
diff --git a/docs/client_errors/MEMCACHED_CLIENT_ERROR.rst b/docs/source/client_errors/MEMCACHED_CLIENT_ERROR.rst
index d8df4683..d8df4683 100644
--- a/docs/client_errors/MEMCACHED_CLIENT_ERROR.rst
+++ b/docs/source/client_errors/MEMCACHED_CLIENT_ERROR.rst
diff --git a/docs/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst b/docs/source/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst
index 221cced1..221cced1 100644
--- a/docs/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_CONNECTION_BIND_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_CONNECTION_FAILURE.rst b/docs/source/client_errors/MEMCACHED_CONNECTION_FAILURE.rst
index 1d2ca04e..1d2ca04e 100644
--- a/docs/client_errors/MEMCACHED_CONNECTION_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_CONNECTION_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst b/docs/source/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst
index 66fd7187..66fd7187 100644
--- a/docs/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst b/docs/source/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst
index 4b5c16aa..4b5c16aa 100644
--- a/docs/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst
+++ b/docs/source/client_errors/MEMCACHED_DATA_DOES_NOT_EXIST.rst
diff --git a/docs/client_errors/MEMCACHED_DATA_EXISTS.rst b/docs/source/client_errors/MEMCACHED_DATA_EXISTS.rst
index 8443cae9..8443cae9 100644
--- a/docs/client_errors/MEMCACHED_DATA_EXISTS.rst
+++ b/docs/source/client_errors/MEMCACHED_DATA_EXISTS.rst
diff --git a/docs/client_errors/MEMCACHED_DELETED.rst b/docs/source/client_errors/MEMCACHED_DELETED.rst
index b2654352..b2654352 100644
--- a/docs/client_errors/MEMCACHED_DELETED.rst
+++ b/docs/source/client_errors/MEMCACHED_DELETED.rst
diff --git a/docs/client_errors/MEMCACHED_DEPRECATED.rst b/docs/source/client_errors/MEMCACHED_DEPRECATED.rst
index 13de9bcd..13de9bcd 100644
--- a/docs/client_errors/MEMCACHED_DEPRECATED.rst
+++ b/docs/source/client_errors/MEMCACHED_DEPRECATED.rst
diff --git a/docs/client_errors/MEMCACHED_E2BIG.rst b/docs/source/client_errors/MEMCACHED_E2BIG.rst
index fdd04958..fdd04958 100644
--- a/docs/client_errors/MEMCACHED_E2BIG.rst
+++ b/docs/source/client_errors/MEMCACHED_E2BIG.rst
diff --git a/docs/client_errors/MEMCACHED_END.rst b/docs/source/client_errors/MEMCACHED_END.rst
index 4372448d..4372448d 100644
--- a/docs/client_errors/MEMCACHED_END.rst
+++ b/docs/source/client_errors/MEMCACHED_END.rst
diff --git a/docs/client_errors/MEMCACHED_ERRNO.rst b/docs/source/client_errors/MEMCACHED_ERRNO.rst
index 60640343..60640343 100644
--- a/docs/client_errors/MEMCACHED_ERRNO.rst
+++ b/docs/source/client_errors/MEMCACHED_ERRNO.rst
diff --git a/docs/client_errors/MEMCACHED_FAILURE.rst b/docs/source/client_errors/MEMCACHED_FAILURE.rst
index 9da69fce..9da69fce 100644
--- a/docs/client_errors/MEMCACHED_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst b/docs/source/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst
index b44fb261..b44fb261 100644
--- a/docs/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst
+++ b/docs/source/client_errors/MEMCACHED_FAIL_UNIX_SOCKET.rst
diff --git a/docs/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst b/docs/source/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst
index cd01172a..cd01172a 100644
--- a/docs/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst
+++ b/docs/source/client_errors/MEMCACHED_FETCH_NOTFINISHED.rst
diff --git a/docs/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst b/docs/source/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst
index 2f64869c..2f64869c 100644
--- a/docs/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_HOST_LOOKUP_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst b/docs/source/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst
index 69032bbd..69032bbd 100644
--- a/docs/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst
+++ b/docs/source/client_errors/MEMCACHED_INVALID_ARGUMENTS.rst
diff --git a/docs/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst b/docs/source/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst
index d6c77234..d6c77234 100644
--- a/docs/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst
+++ b/docs/source/client_errors/MEMCACHED_INVALID_HOST_PROTOCOL.rst
diff --git a/docs/client_errors/MEMCACHED_ITEM.rst b/docs/source/client_errors/MEMCACHED_ITEM.rst
index ee4da97c..ee4da97c 100644
--- a/docs/client_errors/MEMCACHED_ITEM.rst
+++ b/docs/source/client_errors/MEMCACHED_ITEM.rst
diff --git a/docs/client_errors/MEMCACHED_KEY_TOO_BIG.rst b/docs/source/client_errors/MEMCACHED_KEY_TOO_BIG.rst
index c3a58eaa..c3a58eaa 100644
--- a/docs/client_errors/MEMCACHED_KEY_TOO_BIG.rst
+++ b/docs/source/client_errors/MEMCACHED_KEY_TOO_BIG.rst
diff --git a/docs/client_errors/MEMCACHED_MAXIMUM_RETURN.rst b/docs/source/client_errors/MEMCACHED_MAXIMUM_RETURN.rst
index aa7af4ff..aa7af4ff 100644
--- a/docs/client_errors/MEMCACHED_MAXIMUM_RETURN.rst
+++ b/docs/source/client_errors/MEMCACHED_MAXIMUM_RETURN.rst
diff --git a/docs/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst b/docs/source/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst
index fbebfd4d..fbebfd4d 100644
--- a/docs/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_MEMORY_ALLOCATION_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_NOTFOUND.rst b/docs/source/client_errors/MEMCACHED_NOTFOUND.rst
index 55257626..55257626 100644
--- a/docs/client_errors/MEMCACHED_NOTFOUND.rst
+++ b/docs/source/client_errors/MEMCACHED_NOTFOUND.rst
diff --git a/docs/client_errors/MEMCACHED_NOTSTORED.rst b/docs/source/client_errors/MEMCACHED_NOTSTORED.rst
index f10651af..f10651af 100644
--- a/docs/client_errors/MEMCACHED_NOTSTORED.rst
+++ b/docs/source/client_errors/MEMCACHED_NOTSTORED.rst
diff --git a/docs/client_errors/MEMCACHED_NOT_SUPPORTED.rst b/docs/source/client_errors/MEMCACHED_NOT_SUPPORTED.rst
index 5b10b38d..5b10b38d 100644
--- a/docs/client_errors/MEMCACHED_NOT_SUPPORTED.rst
+++ b/docs/source/client_errors/MEMCACHED_NOT_SUPPORTED.rst
diff --git a/docs/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst b/docs/source/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst
index 39c78de5..39c78de5 100644
--- a/docs/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst
+++ b/docs/source/client_errors/MEMCACHED_NO_KEY_PROVIDED.rst
diff --git a/docs/client_errors/MEMCACHED_NO_SERVERS.rst b/docs/source/client_errors/MEMCACHED_NO_SERVERS.rst
index fec92151..fec92151 100644
--- a/docs/client_errors/MEMCACHED_NO_SERVERS.rst
+++ b/docs/source/client_errors/MEMCACHED_NO_SERVERS.rst
diff --git a/docs/client_errors/MEMCACHED_PARSE_ERROR.rst b/docs/source/client_errors/MEMCACHED_PARSE_ERROR.rst
index 173073b9..173073b9 100644
--- a/docs/client_errors/MEMCACHED_PARSE_ERROR.rst
+++ b/docs/source/client_errors/MEMCACHED_PARSE_ERROR.rst
diff --git a/docs/client_errors/MEMCACHED_PARSE_USER_ERROR.rst b/docs/source/client_errors/MEMCACHED_PARSE_USER_ERROR.rst
index 9e3a6292..9e3a6292 100644
--- a/docs/client_errors/MEMCACHED_PARSE_USER_ERROR.rst
+++ b/docs/source/client_errors/MEMCACHED_PARSE_USER_ERROR.rst
diff --git a/docs/client_errors/MEMCACHED_PARTIAL_READ.rst b/docs/source/client_errors/MEMCACHED_PARTIAL_READ.rst
index 78c51e02..78c51e02 100644
--- a/docs/client_errors/MEMCACHED_PARTIAL_READ.rst
+++ b/docs/source/client_errors/MEMCACHED_PARTIAL_READ.rst
diff --git a/docs/client_errors/MEMCACHED_PROTOCOL_ERROR.rst b/docs/source/client_errors/MEMCACHED_PROTOCOL_ERROR.rst
index 0899cb3e..0899cb3e 100644
--- a/docs/client_errors/MEMCACHED_PROTOCOL_ERROR.rst
+++ b/docs/source/client_errors/MEMCACHED_PROTOCOL_ERROR.rst
diff --git a/docs/client_errors/MEMCACHED_READ_FAILURE.rst b/docs/source/client_errors/MEMCACHED_READ_FAILURE.rst
index d929de16..d929de16 100644
--- a/docs/client_errors/MEMCACHED_READ_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_READ_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_SERVER_ERROR.rst b/docs/source/client_errors/MEMCACHED_SERVER_ERROR.rst
index 2cc3164b..2cc3164b 100644
--- a/docs/client_errors/MEMCACHED_SERVER_ERROR.rst
+++ b/docs/source/client_errors/MEMCACHED_SERVER_ERROR.rst
diff --git a/docs/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst b/docs/source/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst
index 2c0e9157..2c0e9157 100644
--- a/docs/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst
+++ b/docs/source/client_errors/MEMCACHED_SERVER_MARKED_DEAD.rst
diff --git a/docs/client_errors/MEMCACHED_SOME_ERRORS.rst b/docs/source/client_errors/MEMCACHED_SOME_ERRORS.rst
index 1217da8e..1217da8e 100644
--- a/docs/client_errors/MEMCACHED_SOME_ERRORS.rst
+++ b/docs/source/client_errors/MEMCACHED_SOME_ERRORS.rst
diff --git a/docs/client_errors/MEMCACHED_STAT.rst b/docs/source/client_errors/MEMCACHED_STAT.rst
index 8b1da4e3..8b1da4e3 100644
--- a/docs/client_errors/MEMCACHED_STAT.rst
+++ b/docs/source/client_errors/MEMCACHED_STAT.rst
diff --git a/docs/client_errors/MEMCACHED_STORED.rst b/docs/source/client_errors/MEMCACHED_STORED.rst
index 9bcc5bf3..9bcc5bf3 100644
--- a/docs/client_errors/MEMCACHED_STORED.rst
+++ b/docs/source/client_errors/MEMCACHED_STORED.rst
diff --git a/docs/client_errors/MEMCACHED_SUCCESS.rst b/docs/source/client_errors/MEMCACHED_SUCCESS.rst
index 633a7087..633a7087 100644
--- a/docs/client_errors/MEMCACHED_SUCCESS.rst
+++ b/docs/source/client_errors/MEMCACHED_SUCCESS.rst
diff --git a/docs/client_errors/MEMCACHED_TIMEOUT.rst b/docs/source/client_errors/MEMCACHED_TIMEOUT.rst
index ea39b3a0..ea39b3a0 100644
--- a/docs/client_errors/MEMCACHED_TIMEOUT.rst
+++ b/docs/source/client_errors/MEMCACHED_TIMEOUT.rst
diff --git a/docs/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst b/docs/source/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst
index 06e168d9..06e168d9 100644
--- a/docs/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_UNKNOWN_READ_FAILURE.rst
diff --git a/docs/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst b/docs/source/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst
index 03ef4157..03ef4157 100644
--- a/docs/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst
+++ b/docs/source/client_errors/MEMCACHED_UNKNOWN_STAT_KEY.rst
diff --git a/docs/client_errors/MEMCACHED_VALUE.rst b/docs/source/client_errors/MEMCACHED_VALUE.rst
index b26fcfb8..b26fcfb8 100644
--- a/docs/client_errors/MEMCACHED_VALUE.rst
+++ b/docs/source/client_errors/MEMCACHED_VALUE.rst
diff --git a/docs/client_errors/MEMCACHED_WRITE_FAILURE.rst b/docs/source/client_errors/MEMCACHED_WRITE_FAILURE.rst
index ca3ba45c..ca3ba45c 100644
--- a/docs/client_errors/MEMCACHED_WRITE_FAILURE.rst
+++ b/docs/source/client_errors/MEMCACHED_WRITE_FAILURE.rst
diff --git a/docs/conf.py.in b/docs/source/conf.py.in
index 7fa47d27..7fa47d27 100644
--- a/docs/conf.py.in
+++ b/docs/source/conf.py.in
diff --git a/docs/error_messages.rst b/docs/source/error_messages.rst
index 34cc3045..34cc3045 100644
--- a/docs/error_messages.rst
+++ b/docs/source/error_messages.rst
diff --git a/docs/hashkit_create.rst b/docs/source/hashkit_create.rst
index a46729a9..a46729a9 100644
--- a/docs/hashkit_create.rst
+++ b/docs/source/hashkit_create.rst
diff --git a/docs/hashkit_functions.rst b/docs/source/hashkit_functions.rst
index 4db41661..4db41661 100644
--- a/docs/hashkit_functions.rst
+++ b/docs/source/hashkit_functions.rst
diff --git a/docs/hashkit_value.rst b/docs/source/hashkit_value.rst
index d27e3528..d27e3528 100644
--- a/docs/hashkit_value.rst
+++ b/docs/source/hashkit_value.rst
diff --git a/docs/index.rst b/docs/source/index.rst
index c3cca3be..c3cca3be 100644
--- a/docs/index.rst
+++ b/docs/source/index.rst
diff --git a/docs/libhashkit.rst b/docs/source/libhashkit.rst
index 8866737a..8866737a 100644
--- a/docs/libhashkit.rst
+++ b/docs/source/libhashkit.rst
diff --git a/docs/libmemcached-1.0/index.rst b/docs/source/libmemcached-1.0/index.rst
index fb8ed307..fb8ed307 100644
--- a/docs/libmemcached-1.0/index.rst
+++ b/docs/source/libmemcached-1.0/index.rst
diff --git a/docs/libmemcached-1.0/memcached_set_encoding_key.rst b/docs/source/libmemcached-1.0/memcached_set_encoding_key.rst
index be38b03f..be38b03f 100644
--- a/docs/libmemcached-1.0/memcached_set_encoding_key.rst
+++ b/docs/source/libmemcached-1.0/memcached_set_encoding_key.rst
diff --git a/docs/libmemcached-1.0/memcached_touch.rst b/docs/source/libmemcached-1.0/memcached_touch.rst
index 76b015cb..76b015cb 100644
--- a/docs/libmemcached-1.0/memcached_touch.rst
+++ b/docs/source/libmemcached-1.0/memcached_touch.rst
diff --git a/docs/libmemcached-1.1/index.rst b/docs/source/libmemcached-1.1/index.rst
index 01c1b31b..01c1b31b 100644
--- a/docs/libmemcached-1.1/index.rst
+++ b/docs/source/libmemcached-1.1/index.rst
diff --git a/docs/libmemcached.rst b/docs/source/libmemcached.rst
index af5ef416..af5ef416 100644
--- a/docs/libmemcached.rst
+++ b/docs/source/libmemcached.rst
diff --git a/docs/libmemcached/defaults.rst b/docs/source/libmemcached/defaults.rst
index 356c0471..356c0471 100644
--- a/docs/libmemcached/defaults.rst
+++ b/docs/source/libmemcached/defaults.rst
diff --git a/docs/libmemcached/memcached_exist.rst b/docs/source/libmemcached/memcached_exist.rst
index 806efe6e..806efe6e 100644
--- a/docs/libmemcached/memcached_exist.rst
+++ b/docs/source/libmemcached/memcached_exist.rst
diff --git a/docs/libmemcached/memcached_fetch.rst b/docs/source/libmemcached/memcached_fetch.rst
index de40c64f..de40c64f 100644
--- a/docs/libmemcached/memcached_fetch.rst
+++ b/docs/source/libmemcached/memcached_fetch.rst
diff --git a/docs/libmemcached/memcached_last_error_message.rst b/docs/source/libmemcached/memcached_last_error_message.rst
index f91f7ae2..f91f7ae2 100644
--- a/docs/libmemcached/memcached_last_error_message.rst
+++ b/docs/source/libmemcached/memcached_last_error_message.rst
diff --git a/docs/libmemcached/memcached_return_t.rst b/docs/source/libmemcached/memcached_return_t.rst
index 9eba3fab..9eba3fab 100644
--- a/docs/libmemcached/memcached_return_t.rst
+++ b/docs/source/libmemcached/memcached_return_t.rst
diff --git a/docs/libmemcached_configuration.rst b/docs/source/libmemcached_configuration.rst
index e0f51b12..e0f51b12 100644
--- a/docs/libmemcached_configuration.rst
+++ b/docs/source/libmemcached_configuration.rst
diff --git a/docs/libmemcached_examples.rst b/docs/source/libmemcached_examples.rst
index a43ee1a2..a43ee1a2 100644
--- a/docs/libmemcached_examples.rst
+++ b/docs/source/libmemcached_examples.rst
diff --git a/docs/libmemcachedutil.rst b/docs/source/libmemcachedutil.rst
index 692aa2ef..692aa2ef 100644
--- a/docs/libmemcachedutil.rst
+++ b/docs/source/libmemcachedutil.rst
diff --git a/docs/memcached_analyze.rst b/docs/source/memcached_analyze.rst
index 88f3ad9d..88f3ad9d 100644
--- a/docs/memcached_analyze.rst
+++ b/docs/source/memcached_analyze.rst
diff --git a/docs/memcached_append.rst b/docs/source/memcached_append.rst
index 0510a316..0510a316 100644
--- a/docs/memcached_append.rst
+++ b/docs/source/memcached_append.rst
diff --git a/docs/memcached_auto.rst b/docs/source/memcached_auto.rst
index 0f78e6e7..0f78e6e7 100644
--- a/docs/memcached_auto.rst
+++ b/docs/source/memcached_auto.rst
diff --git a/docs/memcached_behavior.rst b/docs/source/memcached_behavior.rst
index 7c63d35d..7c63d35d 100644
--- a/docs/memcached_behavior.rst
+++ b/docs/source/memcached_behavior.rst
diff --git a/docs/memcached_callback.rst b/docs/source/memcached_callback.rst
index 0641aa4a..0641aa4a 100644
--- a/docs/memcached_callback.rst
+++ b/docs/source/memcached_callback.rst
diff --git a/docs/memcached_cas.rst b/docs/source/memcached_cas.rst
index a796f303..a796f303 100644
--- a/docs/memcached_cas.rst
+++ b/docs/source/memcached_cas.rst
diff --git a/docs/memcached_create.rst b/docs/source/memcached_create.rst
index ae851ba9..ae851ba9 100644
--- a/docs/memcached_create.rst
+++ b/docs/source/memcached_create.rst
diff --git a/docs/memcached_delete.rst b/docs/source/memcached_delete.rst
index 1c4f2661..1c4f2661 100644
--- a/docs/memcached_delete.rst
+++ b/docs/source/memcached_delete.rst
diff --git a/docs/memcached_dump.rst b/docs/source/memcached_dump.rst
index 988410fc..988410fc 100644
--- a/docs/memcached_dump.rst
+++ b/docs/source/memcached_dump.rst
diff --git a/docs/memcached_flush.rst b/docs/source/memcached_flush.rst
index 042a4d42..042a4d42 100644
--- a/docs/memcached_flush.rst
+++ b/docs/source/memcached_flush.rst
diff --git a/docs/memcached_flush_buffers.rst b/docs/source/memcached_flush_buffers.rst
index 888c9254..888c9254 100644
--- a/docs/memcached_flush_buffers.rst
+++ b/docs/source/memcached_flush_buffers.rst
diff --git a/docs/memcached_generate_hash_value.rst b/docs/source/memcached_generate_hash_value.rst
index 9a9b5a67..9a9b5a67 100644
--- a/docs/memcached_generate_hash_value.rst
+++ b/docs/source/memcached_generate_hash_value.rst
diff --git a/docs/memcached_get.rst b/docs/source/memcached_get.rst
index 59309669..59309669 100644
--- a/docs/memcached_get.rst
+++ b/docs/source/memcached_get.rst
diff --git a/docs/memcached_memory_allocators.rst b/docs/source/memcached_memory_allocators.rst
index 12a4ce5e..12a4ce5e 100644
--- a/docs/memcached_memory_allocators.rst
+++ b/docs/source/memcached_memory_allocators.rst
diff --git a/docs/memcached_pool.rst b/docs/source/memcached_pool.rst
index a3080788..a3080788 100644
--- a/docs/memcached_pool.rst
+++ b/docs/source/memcached_pool.rst
diff --git a/docs/memcached_quit.rst b/docs/source/memcached_quit.rst
index b94832ec..b94832ec 100644
--- a/docs/memcached_quit.rst
+++ b/docs/source/memcached_quit.rst
diff --git a/docs/memcached_result_st.rst b/docs/source/memcached_result_st.rst
index 9b60f187..9b60f187 100644
--- a/docs/memcached_result_st.rst
+++ b/docs/source/memcached_result_st.rst
diff --git a/docs/memcached_sasl.rst b/docs/source/memcached_sasl.rst
index 2a2e5699..2a2e5699 100644
--- a/docs/memcached_sasl.rst
+++ b/docs/source/memcached_sasl.rst
diff --git a/docs/memcached_server_st.rst b/docs/source/memcached_server_st.rst
index 63008795..63008795 100644
--- a/docs/memcached_server_st.rst
+++ b/docs/source/memcached_server_st.rst
diff --git a/docs/memcached_servers.rst b/docs/source/memcached_servers.rst
index d3c90379..d3c90379 100644
--- a/docs/memcached_servers.rst
+++ b/docs/source/memcached_servers.rst
diff --git a/docs/memcached_set.rst b/docs/source/memcached_set.rst
index 6cbebe06..6cbebe06 100644
--- a/docs/memcached_set.rst
+++ b/docs/source/memcached_set.rst
diff --git a/docs/memcached_stats.rst b/docs/source/memcached_stats.rst
index c173619a..c173619a 100644
--- a/docs/memcached_stats.rst
+++ b/docs/source/memcached_stats.rst
diff --git a/docs/memcached_strerror.rst b/docs/source/memcached_strerror.rst
index 07023b8d..07023b8d 100644
--- a/docs/memcached_strerror.rst
+++ b/docs/source/memcached_strerror.rst
diff --git a/docs/memcached_user_data.rst b/docs/source/memcached_user_data.rst
index a0bc602b..a0bc602b 100644
--- a/docs/memcached_user_data.rst
+++ b/docs/source/memcached_user_data.rst
diff --git a/docs/memcached_verbosity.rst b/docs/source/memcached_verbosity.rst
index c3ae0d89..c3ae0d89 100644
--- a/docs/memcached_verbosity.rst
+++ b/docs/source/memcached_verbosity.rst
diff --git a/docs/memcached_version.rst b/docs/source/memcached_version.rst
index 20b8b25a..20b8b25a 100644
--- a/docs/memcached_version.rst
+++ b/docs/source/memcached_version.rst
diff --git a/docs/tap.rst b/docs/source/tap.rst
index 5572f114..5572f114 100644
--- a/docs/tap.rst
+++ b/docs/source/tap.rst
diff --git a/docs/types.rst b/docs/source/types.rst
index ea418749..ea418749 100644
--- a/docs/types.rst
+++ b/docs/source/types.rst
diff --git a/docs/versioning.rst b/docs/source/versioning.rst
index dd3bee9d..dd3bee9d 100644
--- a/docs/versioning.rst
+++ b/docs/source/versioning.rst
diff --git a/libtest/include.am b/libtest/include.am
index b5f48d1a..8968821d 100644
--- a/libtest/include.am
+++ b/libtest/include.am
@@ -161,7 +161,6 @@ libtest_libtest_la_LIBADD+= @PTHREAD_LIBS@
libtest_libtest_la_LIBADD+= $(CURL_LIBS)
libtest_libtest_la_LIBADD+= @RT_LIB@
-EXTRA_libtest_libtest_la_DEPENDENCIES+= libtest_tmp_dir
EXTRA_libtest_libtest_la_DEPENDENCIES+= libtest/abort
EXTRA_libtest_libtest_la_DEPENDENCIES+= libtest/wait
@@ -186,8 +185,7 @@ endif
TMP_DIR := tmp_chroot/etc tmp_chroot/var/log tmp_chroot/var/tmp tmp_chroot/var/run tmp_chroot/var/drizzle
-.PHONY: libtest_tmp_dir
-libtest_tmp_dir: | $(TMP_DIR)
+BUILT_SOURCES+= $(TMP_DIR)
$(TMP_DIR):
@$(mkdir_p) $(TMP_DIR)
diff --git a/man/include.am b/man/include.am
index 602cfa96..c676fcaf 100644
--- a/man/include.am
+++ b/man/include.am
@@ -2,11 +2,11 @@
# included from Top Level Makefile.am
# All paths should be given relative to the root
-# Build rule for documentation
-$(dist_man_MANS): $(top_srcdir)/configure.ac
- $(MAKE) $(AM_MAKEFLAGS) man
+RST_FILES= $(shell find $(top_builddir)/docs/source -type f -name '*.rst')
-.NOTPARALLEL: $(dist_man_MANS)
+# Build rule for documentation
+$(dist_man_MANS): $(RST_FILES)
+ @cp docs/build/$@ $@
dist_man_MANS+= man/memaslap.1
dist_man_MANS+= man/memcapable.1
diff --git a/rpm/include.am b/rpm/include.am
deleted file mode 100644
index 1256ae7a..00000000
--- a/rpm/include.am
+++ /dev/null
@@ -1,36 +0,0 @@
-# vim:ft=automake
-
-rpm-build: support/$(PACKAGE).spec dist
- @rm -f *.rpm
- @rm -f ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-$(VERSION)*.rpm
- @rm -f ~/rpmbuild/SRPMS/$(PACKAGE)-$(VERSION)*.rpm
- @mkdir -p ~/rpmbuild/BUILD/
- @mkdir -p ~/rpmbuild/RPMS/i386/
- @mkdir -p ~/rpmbuild/RPMS/i686/
- @mkdir -p ~/rpmbuild/RPMS/noarch/
- @mkdir -p ~/rpmbuild/RPMS/x86_64/
- @mkdir -p ~/rpmbuild/SOURCES/
- @mkdir -p ~/rpmbuild/SPECS/
- @mkdir -p ~/rpmbuild/SRPMS/
- @cp $(PACKAGE)-$(VERSION).tar.gz ~/rpmbuild/SOURCES/
- @rpmbuild -ba support/$(PACKAGE).spec
- @cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-$(VERSION)*.rpm .
- @cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-devel-$(VERSION)*.rpm .
- -cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-debuginfo-$(VERSION)*.rpm .
- @cp ~/rpmbuild/SRPMS/$(PACKAGE)-$(VERSION)*.rpm .
-
-rpm-sign: rpm-build
- @rpm --addsign *.rpm
- @rpm --checksig *.rpm
-
-clean-rpm:
- @rm -f *.tar.gz
- @rm -f *.src.rpm
- @rm -f *.rpm
-
-rpm: clean-rpm support/$(PACKAGE).spec rpm-build
-
-release: rpm rpm-sign
-
-auto-rpmbuild:
- @auto-br-rpmbuild -ba support/libmemcached.spec
diff --git a/rpm/include.mk b/rpm/include.mk
new file mode 100644
index 00000000..bf9bd1a8
--- /dev/null
+++ b/rpm/include.mk
@@ -0,0 +1,55 @@
+# vim:ft=automake
+
+RPM_BUILDDIR= ~/rpmbuild
+RPM_SOURCESDIR= $(RPM_BUILDDIR)/SOURCES
+
+RPM_BUILD_TARGET= @PACKAGE@-@VERSION@-@RPM_RELEASE@.@build_cpu@.rpm
+RPM_SOURCE= $(RPM_SOURCESDIR)/$(DIST_ARCHIVES)
+
+RPMS=
+RPMS+= $(RPM_BUILD_TARGET)
+RPMS+= @PACKAGE@-devel-@VERSION@-@RPM_RELEASE@.@build_cpu@.rpm
+RPMS+= @PACKAGE@-debuginfo-@VERSION@-@RPM_RELEASE@.@build_cpu@.rpm
+
+SRPMS= @PACKAGE@-@VERSION@-@RPM_RELEASE@.src.rpm
+
+RPM_DIST= $(RPMS) $(SRPMS)
+
+BUILD_RPMS= $(foreach rpm_iterator,$(RPMS),$(addprefix $(RPM_BUILDDIR)/RPMS/@build_cpu@/, $(rpm_iterator)))
+BUILD_SRPMS= $(foreach srpm_iterator,$(SRPMS),$(addprefix $(RPM_BUILDDIR)/SRPMS/, $(srpm_iterator)))
+BUILD_RPM_DIR= $(RPM_BUILDDIR)/BUILD/@PACKAGE@-@VERSION@
+
+$(RPM_BUILDDIR):
+ @@RPMDEV_SETUPTREE@
+
+$(DIST_ARCHIVES): $(DISTFILES)
+ $(MAKE) $(AM_MAKEFLAGS) dist-gzip
+
+$(RPM_SOURCE): $(DIST_ARCHIVES) $(RPM_BUILDDIR)
+ @cp $< $@
+
+$(RPM_BUILD_TARGET): $(RPM_SOURCE) support/@PACKAGE@.spec
+ -@rm -f $(BUILD_RPMS) $(BUILD_SRPMS)
+ -@rm -rf $(BUILD_RPM_DIR)
+ @@RPMBUILD@ -ba $(top_srcdir)/support/@PACKAGE@.spec
+ @cp $(BUILD_RPMS) $(BUILD_SRPMS) .
+
+.PHONY: rpm-sign
+rpm-sign: $(RPM_BUILD_TARGET)
+ @@RPM@ --addsign $(RPM_DIST)
+ @@RPM@ --checksig $(RPM_DIST)
+
+.PHONY: clean-rpm
+clean-rpm:
+ -@rm -f $(BUILD_RPMS) $(BUILD_SRPMS) $(BUILD_RPM_SOURCE) $(RPM_DIST)
+ -@rm -rf $(BUILD_RPM_DIR)
+
+rpm: $(RPM_BUILD_TARGET)
+dist-rpm: $(RPM_BUILD_TARGET)
+
+.PHONY: release
+release: rpm rpm-sign
+
+.PHONY: auto-rpmbuild
+auto-rpmbuild: support/@PACKAGE@.spec
+ @auto-br-rpmbuild -ba $(top_srcdir)/support/@PACKAGE@.spec
diff --git a/support/libmemcached.spec.in b/support/libmemcached.spec.in
index 5749aa13..fe9f6da8 100644
--- a/support/libmemcached.spec.in
+++ b/support/libmemcached.spec.in
@@ -1,7 +1,7 @@
Name: libmemcached
Summary: memcached C library and command line tools
Version: @VERSION@
-Release: 1
+Release: @RPM_RELEASE@
License: BSD
Group: System Environment/Libraries
URL: http://launchpad.net/libmemcached