summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-p2p/dcd/Makefile8
-rw-r--r--net-p2p/dcd/distinfo6
-rw-r--r--net-p2p/dcd/files/dcd.sh.in33
-rw-r--r--net-p2p/dcd/files/patch-src-cmd.dc.h13
4 files changed, 51 insertions, 9 deletions
diff --git a/net-p2p/dcd/Makefile b/net-p2p/dcd/Makefile
index f30207961863..0ae915978c2d 100644
--- a/net-p2p/dcd/Makefile
+++ b/net-p2p/dcd/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= dcd
-PORTVERSION= 0.5.9
+PORTVERSION= 0.6.5
CATEGORIES= net-p2p
MASTER_SITES= http://www.dc.ds.pg.gda.pl/download/sources/stable/
@@ -15,7 +15,7 @@ COMMENT= Direct Connect Hub clone for Unix
USE_BZIP2= yes
GNU_CONFIGURE= yes
-USE_REINPLACE= yes
+USE_RC_SUBR= dcd.sh
CONFIGURE_ENV= CPPFLAGS="${PTHREAD_CFLAGS}" LDFLAGS="${PTHREAD_LIBS}"
@@ -30,10 +30,6 @@ SUB_LIST= CONF_FILES="${CONF_FILES}" CONF_DIR="${PREFIX}/etc/dcd"
.include <bsd.port.pre.mk>
-.if ${OSVERSION} < 500000
-BROKEN= "Does not compile"
-.endif
-
post-patch:
.for f in dcd dcd.console
@${MV} ${WRKSRC}/doc/${f}.2 ${WRKSRC}/doc/${f}.8
diff --git a/net-p2p/dcd/distinfo b/net-p2p/dcd/distinfo
index 8154c611a8ef..973fc7561eec 100644
--- a/net-p2p/dcd/distinfo
+++ b/net-p2p/dcd/distinfo
@@ -1,3 +1,3 @@
-MD5 (dcd-0.5.9.tar.bz2) = 0a46f116137459507bae588a818b0be3
-SHA256 (dcd-0.5.9.tar.bz2) = ad22b767a1faaaa585839cddc5ee0f2ca9ad471b7b3f4aab556e84ca9283c17f
-SIZE (dcd-0.5.9.tar.bz2) = 340164
+MD5 (dcd-0.6.5.tar.bz2) = f73325ce84cfd31dc6ba7c1e885717bd
+SHA256 (dcd-0.6.5.tar.bz2) = 790bb42f6207c5535f892985f8667f2fae32c43f2ee4d1599cd8f5b05493aac9
+SIZE (dcd-0.6.5.tar.bz2) = 346353
diff --git a/net-p2p/dcd/files/dcd.sh.in b/net-p2p/dcd/files/dcd.sh.in
new file mode 100644
index 000000000000..0b6ac79a2a0a
--- /dev/null
+++ b/net-p2p/dcd/files/dcd.sh.in
@@ -0,0 +1,33 @@
+#!/bin/sh
+
+# PROVIDE: dcd
+# REQUIRE: LOGIN
+# KEYWORD: shutdown
+#
+# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
+# to enable this service:
+#
+# dcd_enable (bool): Set to NO by default.
+# Set it to YES to enable dcd.
+
+. %%RC_SUBR%%
+
+name="dcd"
+rcvar=${name}_enable
+
+command=%%PREFIX%%/sbin/dcd
+sig_stop=-KILL
+stop_cmd=stop_cmd
+
+load_rc_config $name
+
+stop_cmd()
+{
+ kill $sig_stop $rc_pid
+ rm -f $pidfile
+}
+
+: ${dcd_enable="NO"}
+
+run_rc_command "$1"
+
diff --git a/net-p2p/dcd/files/patch-src-cmd.dc.h b/net-p2p/dcd/files/patch-src-cmd.dc.h
new file mode 100644
index 000000000000..f49db6649d5d
--- /dev/null
+++ b/net-p2p/dcd/files/patch-src-cmd.dc.h
@@ -0,0 +1,13 @@
+--- src/cmd.dc.h.orig Mon Mar 20 04:03:53 2006
++++ src/cmd.dc.h Fri Apr 28 15:10:57 2006
+@@ -13,6 +13,10 @@
+ #if !defined(__CMD_DC_H__)
+ #define __CMD_DC_H__
+
++#ifndef UINT64_C
++#define UINT64_C(c) (c ## ULL)
++#endif
++
+ typedef struct{
+ userrec_t *usr;
+ char *cmd;