Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Debianization

  • Loading branch information...
commit a1cb5c5c9bb55f2aea338f4a66db2f480092382e 1 parent 2be144a
@seanlynch seanlynch authored
View
14 debian/README.Debian
@@ -0,0 +1,14 @@
+Memcached has two logical uses in this package, a system daemon that can be run
+from the standard /etc/init.d/ interface, or one that can be run from userland
+from a the command line such as
+ /usr/bin/memcached -d
+
+The former has been setup to run through the start-memcached script, reading in
+the configuration from /etc/memcached.conf. The start-memcached script ignores
+certain parameters as discussed in the configuration file itself.
+
+The latter is the binary as provided by Danga, and reads in options from the
+command line, ignoring the Debian-specific configuration file entirely.
+
+ --Jay Bonci
+ jaybonci@debian.org
View
4 debian/README.source
@@ -0,0 +1,4 @@
+This package uses quilt for patch management. Refer to /usr/share/doc/quilt/README.source
+from the package 'quilt' for more information about this system.
+
+ -- David Martínez Moreno <ender@debian.org> Fri, 18 Sep 2009 02:43:54 +0200
View
224 debian/changelog
@@ -0,0 +1,224 @@
+memcached (1.4.4+engine93.g7d48ce7-1) jaunty; urgency=low
+
+ * Update to 1.4.4
+
+ -- Sean Lynch <sean@northscale.com> Thu, 07 Jan 2010 17:56:51 +0000
+
+memcached (1.4.3+engine79.g061baeb-1) karmic; urgency=low
+
+ * Pull in changes to add aggregate stats
+
+ -- Sean Lynch <sean@northscale.com> Mon, 04 Jan 2010 15:49:39 -0800
+
+memcached (1.4.3+git78.g36edef1-1) karmic; urgency=low
+
+ * Package engine branch
+
+ -- Sean Lynch <sean@northscale.com> Wed, 30 Dec 2009 14:11:30 -0800
+
+memcached (1.4.2-1) unstable; urgency=medium
+
+ * New upstream release, primarily bugfixes, some of them critical, hence
+ the urgency:
+ - Reject keys larger than 250 bytes in the binary protocol.
+ - Bounds checking on stats cachedump.
+ - Binary protocol set+cas wasn't returning a new cas ID.
+ - Binary quitq didn't actually close the connection
+ - Slab boundary checking cleanup (bad logic in unreachable code)
+ - Get hit memory optimizations
+ - Disallow -t options that cause the server to not work
+ - Killed off incomplete slab rebalance feature.
+ * debian/patches:
+ - 01_init_script_compliant_with_LSB.patch: Remade as upstream applied a
+ whitespace cleanup script that broke the patch.
+ - 02_manpage_additions.patch: Added missing parameters to the memcached
+ manpage.
+ * Removed TODO from debian/docs.
+
+ -- David Martínez Moreno <ender@debian.org> Fri, 16 Oct 2009 15:09:43 +0200
+
+memcached (1.4.1-1) unstable; urgency=high
+
+ * New upstream release (closes: #545883):
+ - Finally addressed CVE-2009-2415: heap-based buffer overflow in length
+ processing (closes: #540379).
+ - Boundary condition during pipelined decoding caused crash.
+ - Bad initialization during buffer realloc.
+ - Buffer overrun in stats_prefix_find.
+ - Other fixes and cleanups.
+ * Changed the default start to yes in /etc/init.d/memcached as well.
+ * debian/watch updated with new format and URL in code.google.com. Thanks,
+ Monty Taylor.
+ * Added get-orig-source target, thanks to Monty Taylor.
+ * debian/control:
+ - Upgraded Standards-Version to 3.8.3 (no changes).
+ - Added Suggests: libmemcached.
+ - Bumped debhelper dependency and debian/compat to 6.
+ - Added Depends on quilt 0.46-7 in order to use dh_quilt_* helpers.
+ * debian/rules: Added dh_quilt_* helpers.
+ * Added direct patches to source as quilt patches.
+ * debian/README.source: Created such file to shut up lintian pedantic.
+
+ -- David Martínez Moreno <ender@debian.org> Fri, 18 Sep 2009 02:43:54 +0200
+
+memcached (1.4.0-1) unstable; urgency=low
+
+ * New upstream release (closes: #484301, #537239):
+ - New binary protocol, supporting CAS (compare-and-swap).
+ - Non-threaded version is no longer possible, you just choose to run 1
+ thread to have similar behaviour.
+ - Lots of performance bottlenecks fixed (connection starvation,
+ contention, disabling of CAS, locks for hash table expansion...).
+ - Lots of new stats. Main change is that stats now are per-slab where
+ possible.
+ - Code cleanup, lots of bugs fixed, added tests, enhanced documentation.
+
+ -- David Martínez Moreno <ender@debian.org> Sat, 01 Aug 2009 23:26:45 +0200
+
+memcached (1.2.8-2) unstable; urgency=low
+
+ * After some thinking, probably making memcached starting by default is the
+ right thing to do (closes: #536524).
+ * Added status support to init.d script (closes: #528689). Thanks, Peter!
+ * debian/control: Added dependency on lsb-base (>= 3.2-13).
+
+ -- David Martínez Moreno <ender@debian.org> Sat, 11 Jul 2009 00:29:51 +0200
+
+memcached (1.2.8-1) unstable; urgency=high
+
+ * New upstream release, urgency=high because of two critical bugs prior
+ to this release:
+ - In 1.2.7 under multithreaded mode, memcached would never restart
+ accepting connections after hitting the maximum connection limit.
+ - Remove 'stats maps' command, as it is a potential information leak,
+ usable if versions prior to 1.2.8 ever have buffer overflows discovered
+ (CVE-2009-1494). Closes: #526554.
+ - Make -b command (setting the TCP listen backlog) actually work.
+ * debian/rules: Removed obsolete --disable-static.
+
+ -- David Martínez Moreno <ender@debian.org> Sat, 02 May 2009 19:15:49 +0200
+
+memcached (1.2.7-1) unstable; urgency=low
+
+ * New upstream release, released on 4/3/2009.
+ - New statistics.
+ - Added -R option. Limit the number of requests processed by a connection
+ at once. Prevents starving other threads if bulk loading.
+ - Added -b command for setting the tcp listen backlog.
+ - Many minor bugfixes.
+
+ -- David Martínez Moreno <ender@debian.org> Sat, 02 May 2009 18:13:39 +0200
+
+memcached (1.2.6-1) unstable; urgency=low
+
+ * New upstream release (closes: #505037). Released on 29/7/2008.
+ - Major crash fixes.
+ - DTrace support.
+ - Minor updates.
+ * debian/memcached.postrm: Now /var/log/memcached.log is removed on purge.
+ Thanks, jidanni! (closes: #447288).
+
+ -- David Martínez Moreno <ender@debian.org> Sat, 28 Feb 2009 09:43:24 +0000
+
+memcached (1.2.5-1) unstable; urgency=low
+
+ * New upstream release, released on 3/2/2008:
+ - Minor bugfixes.
+ - Added support for Opensolaris.
+ - IPv6 support.
+ - "noreply" mode for many commands.
+ - Made "out of memory· errors more clear.
+ - Added eviction/OOM tracking per slab class.
+
+ -- David Martínez Moreno <ender@debian.org> Fri, 27 Feb 2009 10:48:14 +0000
+
+memcached (1.2.4-1) unstable; urgency=low
+
+ * New upstream release (closes: #454699). Released on 6/12/2007:
+ - Many bug and platform fixes since 1.2.2.
+ - New threading support for stat queries.
+ - New commands 'append', 'prepend', 'gets', and 'cas'.
+ - Updates to the manpage (closes: #441067).
+ - Now memcached has a flag -a to restrict the socket to a group (closes:
+ #446606).
+ * debian/rules: Added memcached-tool to the set of installed scripts.
+ Thanks, Cyril! (closes: #512400).
+
+ -- David Martínez Moreno <ender@debian.org> Thu, 26 Feb 2009 12:07:03 +0000
+
+memcached (1.2.3-1) unstable; urgency=low
+
+ * Take over memcached package.
+ * New upstream release. Mostly a documentation and warning fixing release.
+ This one was released on 6/7/2007.
+ * Added an /etc/default/memcached, thanks to Mark Ferlatte (closes:
+ #467356).
+ * debian/rules: Added --enable-threads to configure. It's amazing how this
+ could be missing from mainstream packages in Debian.
+ * debian/control:
+ - Put myself as Maintainer.
+ - Added Homepage field.
+ - Bumped Standards-Version to 3.8.0.
+ - Added ${misc:Depends} to Depends line.
+ * debian/copyright: Added a lot of information.
+ * debian/memcached.post{inst,rm}: Added set -e in order to catch errors.
+
+ -- David Martínez Moreno <ender@debian.org> Thu, 26 Feb 2009 09:51:46 +0000
+
+memcached (1.2.2-1) unstable; urgency=low
+
+ * New upstream release
+
+ -- Jay Bonci <jaybonci@debian.org> Fri, 29 Jun 2007 10:18:03 -0400
+
+memcached (1.2.1-1) unstable; urgency=low
+
+ * New upstream release (Closes: #405054)
+ * Fix to logfile output so logrotate will work (Closes: #417941)
+ * Listen in on localhost by default (Closes: #383660)
+ * Default configuration suggests nobody by default (Closes: #391351)
+ * Bumped policy version to 3.7.2.2 (No other changes)
+
+ -- Jay Bonci <jaybonci@debian.org> Wed, 02 May 2007 11:35:42 -0400
+
+memcached (1.1.12-1) unstable; urgency=low
+
+ * New upstream version
+ * Updates watchfile so uupdate will work
+
+ -- Jay Bonci <jaybonci@debian.org> Mon, 11 Apr 2005 11:54:39 -0400
+
+memcached (1.1.11-3) unstable; urgency=low
+
+ * Rebuild against non-broken libevent
+
+ -- Jay Bonci <jaybonci@debian.org> Fri, 18 Feb 2005 09:11:55 -0500
+
+memcached (1.1.11-2) unstable; urgency=low
+
+ * Adds debian/watch file so uscan will work
+ * Added additional paragraph to debian/control (Closes: #262069)
+
+ -- Jay Bonci <jaybonci@debian.org> Wed, 27 Oct 2004 13:49:22 -0400
+
+memcached (1.1.11-1) unstable; urgency=low
+
+ * New upstream version
+ * Fix silly typo that kept daemon from running as www-data (Closes: #239854)
+ - Thanks to Karaszi Istvan for the report
+ * Fix to reopen fds as the logfile, adds logfile support (Closes: #243522)
+
+ -- Jay Bonci <jaybonci@debian.org> Wed, 5 May 2004 17:25:25 -0400
+
+memcached (1.1.10-1) unstable; urgency=low
+
+ * New upstream version
+
+ -- Jay Bonci <jaybonci@debian.org> Wed, 31 Dec 2003 10:01:27 -0500
+
+memcached (1.1.9-1) unstable; urgency=low
+
+ * Initial Release (Closes: #206268).
+
+ -- Jay Bonci <jaybonci@debian.org> Wed, 15 Oct 2003 15:53:51 -0400
+
View
1  debian/compat
@@ -0,0 +1 @@
+6
View
26 debian/control
@@ -0,0 +1,26 @@
+Source: memcached
+Section: web
+Priority: optional
+Maintainer: David Martínez Moreno <ender@debian.org>
+Build-Depends: debhelper (>= 6), libevent-dev, quilt (>= 0.46-7)
+Homepage: http://www.danga.com/memcached/
+Standards-Version: 3.8.3
+
+Package: memcached
+Architecture: any
+Depends: ${shlibs:Depends}, perl, ${misc:Depends}, lsb-base (>= 3.2-13)
+Suggests: libcache-memcached-perl, libmemcached
+Description: A high-performance memory object caching system
+ Danga Interactive developed memcached to enhance the speed of LiveJournal.com,
+ a site which was already doing 20 million+ dynamic page views per day for 1
+ million users with a bunch of webservers and a bunch of database servers.
+ memcached dropped the database load to almost nothing, yielding faster page
+ load times for users, better resource utilization, and faster access to the
+ databases on a memcache miss.
+ .
+ memcached optimizes specific high-load serving applications that are designed
+ to take advantage of its versatile no-locking memory access system. Clients
+ are available in several different programming languages, to suit the needs
+ of the specific application. Traditionally this has been used in mod_perl
+ apps to avoid storing large chunks of data in Apache memory, and to share
+ this burden across several machines.
View
58 debian/copyright
@@ -0,0 +1,58 @@
+This package was debianized by Jay Bonci <jaybonci@debian.org> on
+Wed, 15 Oct 2003 15:53:51 -0400.
+
+It was downloaded from http://www.danga.com/memcached
+
+Upstream authors: Brad Fitzpatrick and Danga Interactive <brad@danga.com>
+
+Copyright:
+
+memcached is (C) Danga Interactive 2003-2007
+
+This product includes software developed by Niels Provos (libevent).
+
+libevent is copyright 2000-2003 Niels Provos <provos@citi.umich.edu>
+All rights reserved.
+
+autotools code is Copyright (C) 1992-2007 Free Software Foundation, Inc.
+
+
+License:
+
+The memcached server is licensed under the BSD-style license. The full text of
+that license may be found on a Debian GNU/Linux system in:
+
+/usr/share/common-licenses/BSD
+
+autotools code is licensed under GNU Public License. You may find a copy of this
+license in a Debian GNU/Linux system in:
+
+/usr/share/common-licenses/GPL
+
+
+For libevent:
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+3. All advertising materials mentioning features or use of this software
+ must display the following acknowledgement:
+ This product includes software developed by Niels Provos.
+4. The name of the author may not be used to endorse or promote products
+ derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
View
3  debian/docs
@@ -0,0 +1,3 @@
+NEWS
+README
+doc/protocol.txt
View
47 debian/memcached.conf
@@ -0,0 +1,47 @@
+# memcached default config file
+# 2003 - Jay Bonci <jaybonci@debian.org>
+# This configuration file is read by the start-memcached script provided as
+# part of the Debian GNU/Linux distribution.
+
+# Run memcached as a daemon. This command is implied, and is not needed for the
+# daemon to run. See the README.Debian that comes with this package for more
+# information.
+-d
+
+# Log memcached's output to /var/log/memcached
+logfile /var/log/memcached.log
+
+# Be verbose
+# -v
+
+# Be even more verbose (print client commands as well)
+# -vv
+
+# Start with a cap of 64 megs of memory. It's reasonable, and the daemon default
+# Note that the daemon will grow to this size, but does not start out holding this much
+# memory
+-m 64
+
+# Default connection port is 11211
+-p 11211
+
+# Run the daemon as root. The start-memcached will default to running as root if no
+# -u command is present in this config file
+-u nobody
+
+# Specify which IP address to listen on. The default is to listen on all IP addresses
+# This parameter is one of the only security measures that memcached has, so make sure
+# it's listening on a firewalled interface.
+-l 127.0.0.1
+
+# Limit the number of simultaneous incoming connections. The daemon default is 1024
+# -c 1024
+
+# Lock down all paged memory. Consult with the README and homepage before you do this
+# -k
+
+# Return error when memory is exhausted (rather than removing items)
+# -M
+
+# Maximize core file limit
+# -r
View
2  debian/memcached.default
@@ -0,0 +1,2 @@
+# Set this to no to disable memcached.
+ENABLE_MEMCACHED=yes
View
4 debian/memcached.dirs
@@ -0,0 +1,4 @@
+etc/
+usr/share/doc/memcached
+usr/share/memcached/scripts
+usr/bin
View
1  debian/memcached.manpages
@@ -0,0 +1 @@
+doc/memcached.1
View
11 debian/memcached.postinst
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+set -e
+
+if [ ! -e /etc/memcached.conf ]
+ then
+ mkdir -p /etc
+ cp /usr/share/memcached/memcached.conf.default /etc/memcached.conf
+fi
+
+#DEBHELPER#
View
13 debian/memcached.postrm
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = "purge" ]
+ then
+ rm -f /etc/memcached.conf
+ rm -f /var/log/memcached.log
+fi
+
+ rm -f /var/run/memcached.pid
+
+#DEBHELPER#
View
86 debian/patches/01_init_script_compliant_with_LSB.patch
@@ -0,0 +1,86 @@
+Index: memcached-1.4.2/scripts/memcached-init
+===================================================================
+--- memcached-1.4.2.orig/scripts/memcached-init
++++ memcached-1.4.2/scripts/memcached-init
+@@ -22,38 +24,50 @@ test -x $DAEMONBOOTSTRAP || exit 0
+
+ set -e
+
++. /lib/lsb/init-functions
++
++# Edit /etc/default/memcached to change this.
++ENABLE_MEMCACHED=no
++test -r /etc/default/memcached && . /etc/default/memcached
++
+ case "$1" in
+- start)
+- echo -n "Starting $DESC: "
+- start-stop-daemon --start --quiet --exec $DAEMONBOOTSTRAP
+- echo "$NAME."
+- ;;
+- stop)
+- echo -n "Stopping $DESC: "
+- start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
+- echo "$NAME."
+- rm -f $PIDFILE
+- ;;
+-
+- restart|force-reload)
+- #
+- # If the "reload" option is implemented, move the "force-reload"
+- # option to the "reload" entry above. If not, "force-reload" is
+- # just the same as "restart".
+- #
+- echo -n "Restarting $DESC: "
+- start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE
+- rm -f $PIDFILE
+- sleep 1
+- start-stop-daemon --start --quiet --exec $DAEMONBOOTSTRAP
+- echo "$NAME."
+- ;;
+- *)
+- N=/etc/init.d/$NAME
+- # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
+- echo "Usage: $N {start|stop|restart|force-reload}" >&2
+- exit 1
+- ;;
++ start)
++ echo -n "Starting $DESC: "
++ if [ $ENABLE_MEMCACHED = yes ]; then
++ start-stop-daemon --start --quiet --exec $DAEMONBOOTSTRAP
++ echo "$NAME."
++ else
++ echo "$NAME disabled in /etc/default/memcached."
++ fi
++ ;;
++ stop)
++ echo -n "Stopping $DESC: "
++ start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
++ echo "$NAME."
++ rm -f $PIDFILE
++ ;;
++
++ restart|force-reload)
++ #
++ # If the "reload" option is implemented, move the "force-reload"
++ # option to the "reload" entry above. If not, "force-reload" is
++ # just the same as "restart".
++ #
++ echo -n "Restarting $DESC: "
++ start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE
++ rm -f $PIDFILE
++ sleep 1
++ start-stop-daemon --start --quiet --exec $DAEMONBOOTSTRAP
++ echo "$NAME."
++ ;;
++ status)
++ status_of_proc $DAEMON $NAME
++ ;;
++ *)
++ N=/etc/init.d/$NAME
++ echo "Usage: $N {start|stop|restart|force-reload|status}" >&2
++ exit 1
++ ;;
+ esac
+
+ exit 0
View
58 debian/patches/02_manpage_additions.patch
@@ -0,0 +1,58 @@
+Index: memcached-1.4.2/doc/memcached.1
+===================================================================
+--- memcached-1.4.2.orig/doc/memcached.1
++++ memcached-1.4.2/doc/memcached.1
+@@ -1,4 +1,4 @@
+-.TH MEMCACHED 1 "April 11, 2005"
++.TH MEMCACHED 1 "October 16, 2009"
+ .SH NAME
+ memcached \- high-performance memory object caching system
+ .SH SYNOPSIS
+@@ -95,29 +95,39 @@ Be verbose during the event loop; print
+ Be even more verbose; same as \-v but also print client commands and
+ responses.
+ .TP
++.B \-vvv
++Be extremely verbose; same of the above and also print internal state transitions.
++.TP
+ .B \-i
+ Print memcached and libevent licenses.
+ .TP
++.B \-I
++Override the size of each slab page in bytes. In mundane words, it adjusts the
++maximum item size that memcached will accept. You can use the suffixes \fBK\fR and
++\fBM\fR to specify the size as well, so use 2000000 or 2000K or 2M if you want a
++maximum size of 2 MB per object. It is not recommended to raise this limit above
++1 MB due just to performance reasons. The default value is 1 MB.
++.TP
+ .B \-P <filename>
+ Print pidfile to <filename>, only used under \-d option.
+ .TP
+ .B \-t <threads>
+-Number of threads to use to process incoming requests. This option is only
+-meaningful if memcached was compiled with thread support enabled. It is
++Number of threads to use to process incoming requests. It is
+ typically not useful to set this higher than the number of CPU cores on the
+-memcached server. The default is 4.
++memcached server. Setting a high number (64 or more) of worker
++threads is not recommended. The default is 4.
+ .TP
+ .B \-D <char>
+-Use <char> as the delimiter between key prefixes and IDs. This is used for
+-per-prefix stats reporting. The default is ":" (colon). If this option is
++Use <char> as the delimiter between key prefixes and IDs. This is used for
++per-prefix stats reporting. The default is ":" (colon). If this option is
+ specified, stats collection is turned on automatically; if not, then it may
+ be turned on by sending the "stats detail on" command to the server.
+ .TP
+ .B \-L
+-Try to use large memory pages (if available). Increasing the memory page size
+-could reduce the number of TLB misses and improve the performance. In order to
++Try to use large memory pages (if available). Increasing the memory page size
++could reduce the number of TLB misses and improve the performance. In order to
+ get large pages from the OS, memcached will allocate the total item-cache in
+-one large chunk. Only available if supported on your OS.
++one large chunk. Only available if supported on your OS.
+ .TP
+ .B \-B <proto>
+ Specify the binding protocol to use. By default, the server will
View
2  debian/patches/series
@@ -0,0 +1,2 @@
+01_init_script_compliant_with_LSB.patch
+02_manpage_additions.patch
View
105 debian/rules
@@ -0,0 +1,105 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+# These are used for cross-compiling and for saving the configure script
+# from having to guess our platform (since we know it already)
+DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+PACKAGE=memcached
+PKGBASE=debian/$(PACKAGE)/usr/share/memcached/
+SCRIPTS=$(PKGBASE)/scripts
+
+CFLAGS=-Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+ CFLAGS +=-O0
+else
+ CFLAGS +=-O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+ INSTALL_PROGRAM += -s
+endif
+
+get-orig-source:
+ uscan --verbose --force-download --rename --repack --destdir=..
+
+config.status: configure
+ dh_testdir
+ CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) \
+ --build=$(DEB_BUILD_GNU_TYPE) \
+ --prefix=/usr \
+ --mandir=\$${prefix}/share/man \
+ --infodir=\$${prefix}/share/info \
+ --enable-sasl
+
+build: build-stamp
+
+build-stamp: config.status
+ dh_quilt_patch
+ dh_testdir
+
+ $(MAKE)
+
+ touch build-stamp
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-stamp config.log
+ rm -f debian/memcached.init
+ # Add here commands to clean up after the build process.
+ [ ! -f Makefile ] || $(MAKE) distclean
+
+ dh_quilt_unpatch
+ dh_clean
+
+install: build
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+ dh_installdirs
+
+ # Add here commands to install the package into debian/memcached.
+ $(MAKE) install DESTDIR=$(CURDIR)/debian/memcached
+ #install -d $(CURDIR)/$(PKGBASE)
+ install -m 644 $(CURDIR)/debian/memcached.conf $(CURDIR)/$(PKGBASE)/memcached.conf.default
+ #install -d $(SCRIPTS)
+ install -m 744 $(CURDIR)/scripts/start-memcached $(SCRIPTS)
+ install -m 744 $(CURDIR)/scripts/memcached-tool $(SCRIPTS)
+ install -m 755 $(CURDIR)/scripts/memcached-init $(CURDIR)/debian/memcached.init
+
+
+# Build architecture-independent files here.
+binary-indep:;
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+ dh_testdir
+ dh_testroot
+ dh_installchangelogs ChangeLog
+ dh_installdocs
+ dh_installexamples
+ dh_install
+ dh_installdebconf
+ dh_installinit
+ dh_installman
+ dh_link
+ dh_strip
+ dh_compress
+ dh_fixperms
+ dh_installdeb
+ dh_shlibdeps
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install
View
6 debian/watch
@@ -0,0 +1,6 @@
+# format version number, currently 3; this line is compulsory!
+version=3
+
+# code.google.com/p/$project/downloads/list has links to $project.googlecode.com/files/
+opts="versionmangle=s/beta/~b/" http://code.google.com/p/memcached/downloads/list \
+ http://memcached.googlecode.com/files/memcached-(.*)\.tar\.gz
Please sign in to comment.
Something went wrong with that request. Please try again.