From f5accdc1329dfc470da50ab05edf9000a0440482 Mon Sep 17 00:00:00 2001 From: ajacoutot Date: Sat, 13 Nov 2010 06:52:41 +0000 Subject: [PATCH] Add rc script. While here, add @conflict with ircd-ratbox. --- net/ircd-hybrid/Makefile | 5 +++-- net/ircd-hybrid/pkg/MESSAGE | 8 -------- net/ircd-hybrid/pkg/PLIST | 4 +++- net/ircd-hybrid/pkg/ircd_hybrid.rc | 13 +++++++++++++ 4 files changed, 19 insertions(+), 11 deletions(-) delete mode 100644 net/ircd-hybrid/pkg/MESSAGE create mode 100644 net/ircd-hybrid/pkg/ircd_hybrid.rc diff --git a/net/ircd-hybrid/Makefile b/net/ircd-hybrid/Makefile index 7cba787e98e..1b3a79605f4 100644 --- a/net/ircd-hybrid/Makefile +++ b/net/ircd-hybrid/Makefile @@ -1,10 +1,11 @@ -# $OpenBSD: Makefile,v 1.12 2010/11/11 14:00:45 espie Exp $ +# $OpenBSD: Makefile,v 1.13 2010/11/13 06:52:41 ajacoutot Exp $ SHARED_ONLY = Yes + COMMENT = Internet Relay Chat server DISTNAME = ircd-hybrid-7.2.3 -REVISION = 7 +REVISION = 8 CATEGORIES = net HOMEPAGE = http://ircd-hybrid.com/ diff --git a/net/ircd-hybrid/pkg/MESSAGE b/net/ircd-hybrid/pkg/MESSAGE deleted file mode 100644 index 28e352a7cc6..00000000000 --- a/net/ircd-hybrid/pkg/MESSAGE +++ /dev/null @@ -1,8 +0,0 @@ -To start ircd-hybrid at boot time, edit ${SYSCONFDIR}/ircd-hybrid/ircd.conf -as required and insert the following into /etc/rc.local. - -if [ -x ${TRUEPREFIX}/bin/ircd ]; then - echo -n ' ircd' - install -d -o _ircd-hybrid /var/run/ircd - ${TRUEPREFIX}/bin/ircd -fi diff --git a/net/ircd-hybrid/pkg/PLIST b/net/ircd-hybrid/pkg/PLIST index 7ea928b1521..aa77077cb4c 100644 --- a/net/ircd-hybrid/pkg/PLIST +++ b/net/ircd-hybrid/pkg/PLIST @@ -1,6 +1,7 @@ -@comment $OpenBSD: PLIST,v 1.3 2009/02/07 09:58:42 simon Exp $ +@comment $OpenBSD: PLIST,v 1.4 2010/11/13 06:52:41 ajacoutot Exp $ @conflict bnc-* @conflict irc-* +@conflict ircd-ratbox-* @newgroup _ircd-hybrid:616 @newuser _ircd-hybrid:616:616:daemon:IRC Daemon:/var/empty:/sbin/nologin @bin bin/encspeed @@ -259,5 +260,6 @@ share/ircd-hybrid/messages/ircd-polish.lang share/ircd-hybrid/messages/ircd-russian.lang share/ircd-hybrid/messages/ircd-spanish.lang share/ircd-hybrid/messages/ircd-swedish.lang +@rcscript ${RCDIR}/ircd_hybrid @owner _ircd-hybrid @sample /var/log/ircd-hybrid/ diff --git a/net/ircd-hybrid/pkg/ircd_hybrid.rc b/net/ircd-hybrid/pkg/ircd_hybrid.rc new file mode 100644 index 00000000000..9f2bffadbff --- /dev/null +++ b/net/ircd-hybrid/pkg/ircd_hybrid.rc @@ -0,0 +1,13 @@ +#!/bin/sh +# +# $OpenBSD: ircd_hybrid.rc,v 1.1 2010/11/13 06:52:41 ajacoutot Exp $ + +. /etc/rc.d/rc.subr + +daemon="${TRUEPREFIX}/bin/ircd" + +rc_pre() { + install -d -o _ircd-hybrid -g _ircd-hybrid /var/run/ircd +} + +rc_cmd $1