aboutsummaryrefslogtreecommitdiffstats
path: root/databases/memcached
diff options
context:
space:
mode:
authorseanc <seanc@FreeBSD.org>2003-07-22 14:16:06 +0800
committerseanc <seanc@FreeBSD.org>2003-07-22 14:16:06 +0800
commitd5978ce49da2c877f237affe6f86b0fe165dec35 (patch)
tree880c37688590f75484cba526ff454bf4f7a51cbc /databases/memcached
parent4017bc7a7e91e207e02b22162a7a2b74af5a4abf (diff)
downloadfreebsd-ports-graphics-d5978ce49da2c877f237affe6f86b0fe165dec35.tar.gz
freebsd-ports-graphics-d5978ce49da2c877f237affe6f86b0fe165dec35.tar.zst
freebsd-ports-graphics-d5978ce49da2c877f237affe6f86b0fe165dec35.zip
Add memcached: a high-performance, distributed memory object caching
system, generic in nature, but intended for use in speeding up dynamic web applications by alleviating database load.
Diffstat (limited to 'databases/memcached')
-rw-r--r--databases/memcached/Makefile24
-rw-r--r--databases/memcached/distinfo1
-rw-r--r--databases/memcached/files/patch-Makefile.am11
-rw-r--r--databases/memcached/files/patch-assoc.c10
-rw-r--r--databases/memcached/files/patch-configure.ac23
-rw-r--r--databases/memcached/files/patch-items.c11
-rw-r--r--databases/memcached/files/patch-memcached.c57
-rw-r--r--databases/memcached/files/patch-slabs.c10
-rw-r--r--databases/memcached/pkg-descr5
-rw-r--r--databases/memcached/pkg-plist1
10 files changed, 153 insertions, 0 deletions
diff --git a/databases/memcached/Makefile b/databases/memcached/Makefile
new file mode 100644
index 00000000000..b7a1e9ab6a3
--- /dev/null
+++ b/databases/memcached/Makefile
@@ -0,0 +1,24 @@
+# New ports collection makefile for: memcached
+# Date created: July 21, 2003
+# Whom: Sean Chittenden <seanc@FreeBSD.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME?= memcached
+PORTVERSION?= 1.1.6
+CATEGORIES?= databases
+MASTER_SITES= http://www.danga.com/memcached/
+
+MAINTAINER?= seanc@FreeBSD.org
+COMMENT= High-performance distributed memory object cache system
+
+USE_AUTOMAKE=YES
+WANT_AUTOCONF_VER=253
+GNU_CONFIGURE= YES
+
+CONFIGURE_ARGS+= --with-libevent=${LOCALBASE}
+
+BUILD_DEPENDS+= ${LOCALBASE}/lib/libevent.a:${PORTSDIR}/devel/libevent
+
+.include <bsd.port.mk>
diff --git a/databases/memcached/distinfo b/databases/memcached/distinfo
new file mode 100644
index 00000000000..a31b47da3c9
--- /dev/null
+++ b/databases/memcached/distinfo
@@ -0,0 +1 @@
+MD5 (memcached-1.1.6.tar.gz) = e175c78e66b9120aa2c007f2bbacc2b4
diff --git a/databases/memcached/files/patch-Makefile.am b/databases/memcached/files/patch-Makefile.am
new file mode 100644
index 00000000000..e582cacda00
--- /dev/null
+++ b/databases/memcached/files/patch-Makefile.am
@@ -0,0 +1,11 @@
+--- Makefile.am.orig Mon Jul 21 23:04:08 2003
++++ Makefile.am Mon Jul 21 23:04:18 2003
+@@ -5,6 +5,7 @@
+ DIST_SUBDIRS = website api
+ EXTRA_DIST = website api
+
+-CFLAGS=-g -O2 -static -DNDEBUG
++CFLAGS=-g -O2 -static -DNDEBUG @LIBEVENT_CFLAGS@
++LDFLAGS=@LIBEVENT_LDFLAGS@
+
+
diff --git a/databases/memcached/files/patch-assoc.c b/databases/memcached/files/patch-assoc.c
new file mode 100644
index 00000000000..f5af4c8c788
--- /dev/null
+++ b/databases/memcached/files/patch-assoc.c
@@ -0,0 +1,10 @@
+--- assoc.c.orig Mon Jul 21 22:58:06 2003
++++ assoc.c Mon Jul 21 22:58:11 2003
+@@ -28,7 +28,6 @@
+ #include <netinet/in.h>
+ #include <errno.h>
+ #include <event.h>
+-#include <malloc.h>
+ #include <assert.h>
+
+ #include "memcached.h"
diff --git a/databases/memcached/files/patch-configure.ac b/databases/memcached/files/patch-configure.ac
new file mode 100644
index 00000000000..c6e5a730433
--- /dev/null
+++ b/databases/memcached/files/patch-configure.ac
@@ -0,0 +1,23 @@
+--- configure.ac.orig Mon Jul 21 23:03:01 2003
++++ configure.ac Mon Jul 21 23:03:38 2003
+@@ -20,9 +20,20 @@
+ AC_MSG_RESULT(yes)
+ fi
+
++AC_ARG_WITH(libevent,[ --with-libevent=PREFIX Prefix where libevent is installed], libevent_prefix="$withval", libevent_prefix="")
++LIBEVENT_LDFLAGS="-L$libevent_prefix/lib"
++LIBEVENT_CFLAGS="-I$libevent_prefix/include"
++
++LDFLAGS="$LIBEVENT_LDFLAGS"
++CFLAGS="$LIBEVENT_CFLAGS"
++LDADD="$LIBEVENT_LDFLAGS"
++
+ LIBEVENT_URL=http://www.monkey.org/~provos/libevent/
+ AC_CHECK_LIB(event, event_set, ,
+ [AC_MSG_ERROR(libevent is required. You can get it from $LIBEVENT_URL)])
++
++AC_SUBST(LIBEVENT_LDFLAGS)
++AC_SUBST(LIBEVENT_CFLAGS)
+
+ AC_CONFIG_FILES(Makefile)
+ AC_OUTPUT
diff --git a/databases/memcached/files/patch-items.c b/databases/memcached/files/patch-items.c
new file mode 100644
index 00000000000..1af3cd3cdf8
--- /dev/null
+++ b/databases/memcached/files/patch-items.c
@@ -0,0 +1,11 @@
+--- items.c.orig Mon Jul 21 22:57:51 2003
++++ items.c Mon Jul 21 22:57:58 2003
+@@ -17,8 +17,6 @@
+ #include <errno.h>
+ #include <time.h>
+ #include <event.h>
+-#include <malloc.h>
+-#include <Judy.h>
+ #include <assert.h>
+
+ #include "memcached.h"
diff --git a/databases/memcached/files/patch-memcached.c b/databases/memcached/files/patch-memcached.c
new file mode 100644
index 00000000000..481e64fdbc2
--- /dev/null
+++ b/databases/memcached/files/patch-memcached.c
@@ -0,0 +1,57 @@
+--- memcached.c.orig Mon Jul 21 22:56:55 2003
++++ memcached.c Mon Jul 21 22:58:46 2003
+@@ -34,7 +34,6 @@
+ #include <errno.h>
+ #include <time.h>
+ #include <event.h>
+-#include <malloc.h>
+ #include <assert.h>
+
+ #include "memcached.h"
+@@ -293,26 +292,6 @@
+ return;
+ }
+
+- if (strcmp(command, "stats malloc") == 0) {
+- char temp[512];
+- struct mallinfo info;
+- char *pos = temp;
+-
+- info = mallinfo();
+- pos += sprintf(pos, "STAT arena_size %d\r\n", info.arena);
+- pos += sprintf(pos, "STAT free_chunks %d\r\n", info.ordblks);
+- pos += sprintf(pos, "STAT fastbin_blocks %d\r\n", info.smblks);
+- pos += sprintf(pos, "STAT mmapped_regions %d\r\n", info.hblks);
+- pos += sprintf(pos, "STAT mmapped_space %d\r\n", info.hblkhd);
+- pos += sprintf(pos, "STAT max_total_alloc %d\r\n", info.usmblks);
+- pos += sprintf(pos, "STAT fastbin_space %d\r\n", info.fsmblks);
+- pos += sprintf(pos, "STAT total_alloc %d\r\n", info.uordblks);
+- pos += sprintf(pos, "STAT total_free %d\r\n", info.fordblks);
+- pos += sprintf(pos, "STAT releasable_space %d\r\nEND", info.keepcost);
+- out_string(c, temp);
+- return;
+- }
+-
+ if (strcmp(command, "stats maps") == 0) {
+ char *wbuf;
+ int wsize = 8192; /* should be enough */
+@@ -1089,7 +1068,6 @@
+ printf("-d run as a daemon\n");
+ printf("-m <num> max memory to use for items in megabytes, default is 64 MB\n");
+ printf("-c <num> max simultaneous connections, default is 1024\n");
+- printf("-k lock down all paged memory\n");
+ printf("-v verbose (print errors/warnings while in event loop)\n");
+ printf("-h print this help and exit\n");
+ printf("-i print memcached and libevent license\n");
+@@ -1236,11 +1214,6 @@
+ fprintf(stderr, "failed to daemon() in order to daemonize\n");
+ return 1;
+ }
+- }
+-
+- /* lock paged memory if needed */
+- if (lock_memory) {
+- mlockall(MCL_CURRENT | MCL_FUTURE);
+ }
+
+ /* create the listening socket and bind it */
diff --git a/databases/memcached/files/patch-slabs.c b/databases/memcached/files/patch-slabs.c
new file mode 100644
index 00000000000..3b6f6bf15c6
--- /dev/null
+++ b/databases/memcached/files/patch-slabs.c
@@ -0,0 +1,10 @@
+--- slabs.c.orig Mon Jul 21 23:08:11 2003
++++ slabs.c Mon Jul 21 23:08:18 2003
+@@ -20,7 +20,6 @@
+ #include <netinet/in.h>
+ #include <errno.h>
+ #include <event.h>
+-#include <malloc.h>
+ #include <assert.h>
+
+ #include "memcached.h"
diff --git a/databases/memcached/pkg-descr b/databases/memcached/pkg-descr
new file mode 100644
index 00000000000..13b7e1bf31d
--- /dev/null
+++ b/databases/memcached/pkg-descr
@@ -0,0 +1,5 @@
+memcached is a high-performance, distributed memory object caching
+system, generic in nature, but intended for use in speeding up dynamic
+web applications by alleviating database load.
+
+WWW: http://www.danga.com/memcached/
diff --git a/databases/memcached/pkg-plist b/databases/memcached/pkg-plist
new file mode 100644
index 00000000000..06386d4f54e
--- /dev/null
+++ b/databases/memcached/pkg-plist
@@ -0,0 +1 @@
+bin/memcached