summaryrefslogtreecommitdiff
path: root/chat
diff options
context:
space:
mode:
authortonnerre <tonnerre@pkgsrc.org>2013-11-05 02:13:42 +0000
committertonnerre <tonnerre@pkgsrc.org>2013-11-05 02:13:42 +0000
commitbb93424250ea0dca9ad0e79857fe9e1b729d41b1 (patch)
tree3cfb2196957b39291fd5beede79abbf611c77ac0 /chat
parent46fe1e663fb1227c1c00a9e1d102def7f8984401 (diff)
downloadpkgsrc-bb93424250ea0dca9ad0e79857fe9e1b729d41b1.tar.gz
Fix the dependencies of the kgb-bot package and add an init script. Bump
pkg_revision.
Diffstat (limited to 'chat')
-rw-r--r--chat/kgb-bot/Makefile21
-rw-r--r--chat/kgb-bot/PLIST1
-rw-r--r--chat/kgb-bot/files/kgb_bot.sh16
3 files changed, 35 insertions, 3 deletions
diff --git a/chat/kgb-bot/Makefile b/chat/kgb-bot/Makefile
index f1812277bab..c87f1ae967f 100644
--- a/chat/kgb-bot/Makefile
+++ b/chat/kgb-bot/Makefile
@@ -1,8 +1,9 @@
-# $NetBSD: Makefile,v 1.1.1.1 2013/10/20 14:16:16 tonnerre Exp $
+# $NetBSD: Makefile,v 1.2 2013/11/05 02:13:42 tonnerre Exp $
#
-PKGNAME= kgb-bot-1.31
-DISTNAME= ${PKGNAME:S/kgb-bot/App-KGB/}
+DISTNAME= App-KGB-1.31
+PKGNAME= ${DISTNAME:S/App-KGB/kgb-bot/}
+PKGREVISION= 1
CATEGORIES= chat perl5 scm
MASTER_SITES= ${MASTER_SITE_PERL_CPAN:=App/}
@@ -22,6 +23,14 @@ DEPENDS+= p5-YAML-[0-9]*:../../textproc/p5-YAML
DEPENDS+= p5-File-Touch-[0-9]*:../../devel/p5-File-Touch
DEPENDS+= p5-WWW-Shorten-[0-9]*:../../www/p5-WWW-Shorten
DEPENDS+= p5-JSON-RPC-[0-9]*:../../www/p5-JSON-RPC
+DEPENDS+= p5-POE-[0-9]*:../../devel/p5-POE
+DEPENDS+= p5-POE-Component-IRC-[0-9]*:../../chat/p5-POE-Component-IRC
+DEPENDS+= p5-POE-Component-Server-SOAP-[0-9]*:../../www/p5-POE-Component-Server-SOAP
+DEPENDS+= p5-Proc-PID-File-[0-9]*:../../devel/p5-Proc-PID-File
+DEPENDS+= p5-Schedule-RateLimiter-[0-9]*:../../devel/p5-Schedule-RateLimiter
+
+RCD_SCRIPTS= kgb_bot
+RCD_SCRIPT_SRC.kgb_bot= files/kgb_bot.sh
REPLACE_INTERPRETER+= perl
REPLACE.perl.old= /usr/bin/perl
@@ -30,6 +39,12 @@ REPLACE_FILES.perl= script/kgb-add-project script/kgb-bot
REPLACE_FILES.perl+= script/kgb-split-config script/kgb-client
REPLACE_FILES.perl+= eg/simple-soap-client eg/simple-soap-server
+SUBST_CLASSES+= configs
+SUBST_STAGE.configs= pre-configure
+SUBST_FILES.configs= script/kgb-add-project script/kgb-bot
+SUBST_FILES.configs+= script/kgb-split-config
+SUBST_SED.configs= -e "s,/etc/,${PKG_SYSCONFDIR}/,g"
+
MAKE_ENV+= PERL=${TOOLS_PATH.perl}
PERL5_PACKLIST= auto/App/KGB/.packlist
diff --git a/chat/kgb-bot/PLIST b/chat/kgb-bot/PLIST
new file mode 100644
index 00000000000..8e88ec9f0c0
--- /dev/null
+++ b/chat/kgb-bot/PLIST
@@ -0,0 +1 @@
+share/examples/rc.d/kgb_bot
diff --git a/chat/kgb-bot/files/kgb_bot.sh b/chat/kgb-bot/files/kgb_bot.sh
new file mode 100644
index 00000000000..6865d066717
--- /dev/null
+++ b/chat/kgb-bot/files/kgb_bot.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+#
+# $NetBSD: kgb_bot.sh,v 1.1 2013/11/05 02:13:42 tonnerre Exp $
+#
+# PROVIDE: kgb_bot
+# REQUIRE: DAEMON
+
+. /etc/rc.subr
+
+name="kgb_bot"
+rcvar=$name
+command="@PREFIX@/sbin/kgb-bot"
+required_files="@PKG_SYSCONFDIR@/kgb-bot/kgb.conf"
+
+load_rc_config $name
+run_rc_command "$1"