summaryrefslogtreecommitdiff
path: root/community/unrealircd
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2013-05-14 01:18:40 -0700
committerroot <root@rshg054.dnsready.net>2013-05-14 01:18:40 -0700
commit2e5b72e5e8dfb5199a9b0da7c76d052a456662c2 (patch)
treefa055d4e2f367acb518de6c4e06b77b6d8cbef75 /community/unrealircd
parent66cb4a487ad73063c6b000279a5d5558fb7603f5 (diff)
Tue May 14 01:18:40 PDT 2013
Diffstat (limited to 'community/unrealircd')
-rw-r--r--community/unrealircd/PKGBUILD17
-rw-r--r--community/unrealircd/unrealircd.rc62
2 files changed, 10 insertions, 69 deletions
diff --git a/community/unrealircd/PKGBUILD b/community/unrealircd/PKGBUILD
index 244544976..f04ab0934 100644
--- a/community/unrealircd/PKGBUILD
+++ b/community/unrealircd/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 82103 2013-01-08 15:57:53Z spupykin $
+# $Id: PKGBUILD 90731 2013-05-13 14:39:46Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Zerial <fernando@zerial.org>
pkgname=unrealircd
pkgver=3.2.10
-pkgrel=1
+pkgrel=2
pkgdesc="Open Source IRC Server"
arch=('i686' 'x86_64')
url="http://unrealircd.com"
@@ -15,17 +15,13 @@ provides=('ircd')
backup=('etc/unrealircd/unrealircd.conf'
'etc/conf.d/unrealircd')
source=(http://www.unrealircd.com/downloads/Unreal$pkgver.tar.gz
- unrealircd.rc
unrealircd.service
arch-fixes.patch)
md5sums=('05b0bbdbfab9ffc2304f7595951d7cec'
- '07ffa1e82a01f319a8b997e155d2af1d'
'2103ce8a4a4e79f6955920bfebea0202'
'77807313c4578f2c30286b9f9e3fb21c')
build() {
- mkdir -p $pkgdir/etc/unrealircd
- mkdir -p $pkgdir/usr/bin
cd $srcdir/Unreal$pkgver
patch -p1 <$srcdir/arch-fixes.patch
@@ -44,6 +40,14 @@ build() {
--with-system-cares
make
+}
+
+package() {
+ cd $srcdir/Unreal$pkgver
+
+ mkdir -p $pkgdir/etc/unrealircd
+ mkdir -p $pkgdir/usr/bin
+
make IRCDDIR=$pkgdir/etc/unrealircd BINDIR=$pkgdir/usr/bin install
mv $srcdir/Unreal$pkgver/src/ircd $pkgdir/usr/bin/unrealircd
@@ -51,7 +55,6 @@ build() {
mkdir -p $pkgdir/usr/lib/unrealircd
mv $pkgdir/etc/unrealircd/modules $pkgdir/usr/lib/unrealircd/
ln -s /usr/lib/unrealircd/modules $pkgdir/etc/unrealircd/modules
- install -D -m0755 $srcdir/unrealircd.rc $pkgdir/etc/rc.d/unrealircd
# log
mkdir -p $pkgdir/var/log/unrealircd/
diff --git a/community/unrealircd/unrealircd.rc b/community/unrealircd/unrealircd.rc
deleted file mode 100644
index 2cede46c8..000000000
--- a/community/unrealircd/unrealircd.rc
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/bash
-
-daemon_name=unrealircd
-
-. /etc/conf.d/unrealircd
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-get_pid() {
- pidof ircd unrealircd
-}
-
-case "$1" in
- start)
- stat_busy "Starting $daemon_name daemon"
-
- PID=`get_pid`
- if [ -z "$PID" ]; then
- [ -f /var/run/$daemon_name.pid ] && rm -f /var/run/$daemon_name.pid
- # RUN
- export PID_FILE="/var/run/unrealircd.pid"
- su -c /usr/bin/unrealircd -p - $UNREALIRCD_USER 1>>/var/log/unrealircd/ircd.log 2>>/var/log/unrealircd/ircd.log
- #
- if [ $? -gt 0 ]; then
- stat_fail
- exit 1
- else
- echo `get_pid` > /var/run/$daemon_name.pid
- add_daemon $daemon_name
- stat_done
- fi
- else
- stat_fail
- exit 1
- fi
- ;;
-
- stop)
- stat_busy "Stopping $daemon_name daemon"
- PID=`get_pid`
- # KILL
- [ ! -z "$PID" ] && kill $PID &> /dev/null
- #
- if [ $? -gt 0 ]; then
- stat_fail
- exit 1
- else
- rm -f /var/run/$daemon_name.pid &> /dev/null
- rm_daemon $daemon_name
- stat_done
- fi
- ;;
-
- restart)
- $0 stop
- sleep 3
- $0 start
- ;;
- *)
- echo "usage: $0 {start|stop|restart}"
-esac
-exit 0