summaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2011-01-21 21:03:25 -0600
committerWilliam Pitcock <nenolod@dereferenced.org>2011-01-21 21:03:25 -0600
commitc9b61c7acdd938205831fb72a20cdac82d7effd5 (patch)
tree4859c94d1c790a3d2715cf031c5ad6418b4da8d1 /main
parent076b0e6a2f5c5aa8a576896fb1be98be05723179 (diff)
downloadaports-c9b61c7acdd938205831fb72a20cdac82d7effd5.tar.bz2
aports-c9b61c7acdd938205831fb72a20cdac82d7effd5.tar.xz
main/bitlbee: promote from testing
Diffstat (limited to 'main')
-rw-r--r--main/bitlbee/APKBUILD54
-rw-r--r--main/bitlbee/bitlbee.confd9
-rw-r--r--main/bitlbee/bitlbee.initd29
-rw-r--r--main/bitlbee/bitlbee.post-install4
4 files changed, 96 insertions, 0 deletions
diff --git a/main/bitlbee/APKBUILD b/main/bitlbee/APKBUILD
new file mode 100644
index 000000000..76f3928a7
--- /dev/null
+++ b/main/bitlbee/APKBUILD
@@ -0,0 +1,54 @@
+# Contributor: Kiyoshi Aman <kiyoshi.aman@gmail.com>
+# Maintainer: Kiyoshi Aman <kiyoshi.aman@gmail.com>
+pkgname=bitlbee
+pkgver=3.0.1
+pkgrel=2
+pkgdesc="An IRC to other chat networks gateway"
+url="http://www.bitlbee.org/"
+arch="all"
+license="GPL-2"
+depends=
+makedepends="glib-dev openssl-dev libotr-dev"
+install="$pkgname.post-install"
+subpackages="$pkgname-doc $pkgname-otr"
+source="
+ http://get.bitlbee.org/src/$pkgname-$pkgver.tar.gz
+ $pkgname.initd
+ $pkgname.confd
+ $pkgname.post-install
+ "
+
+_builddir="$srcdir/$pkgname-$pkgver"
+prepare() {
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
+}
+
+build() {
+ cd "$_builddir"
+ ./configure --ssl=openssl --otr=plugin --prefix=/usr || return 1
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install || return 1
+
+ install -m755 -D "$srcdir"/$pkgname.initd \
+ "$pkgdir"/etc/init.d/$pkgname || return 1
+ install -m644 -D "$srcdir"/$pkgname.confd \
+ "$pkgdir"/etc/conf.d/$pkgname || return 1
+}
+otr() {
+ mkdir -p "$subpkgdir"/usr/lib
+ mv "$pkgdir"/usr/lib/bitlbee "$subpkgdir"/usr/lib
+}
+
+md5sums="4d00c6e09859b653f955b16b988db0ac bitlbee-3.0.1.tar.gz
+4c1e2903cb2f1010cdb941897de1ca23 bitlbee.initd
+bf07d39a4b652c63415b411229c5e281 bitlbee.confd"
diff --git a/main/bitlbee/bitlbee.confd b/main/bitlbee/bitlbee.confd
new file mode 100644
index 000000000..99f308cd9
--- /dev/null
+++ b/main/bitlbee/bitlbee.confd
@@ -0,0 +1,9 @@
+# Sample conf.d file for alpine linux
+
+#
+# Specify daemon options here.
+#
+
+PORT="6667"
+OPTS="-F"
+
diff --git a/main/bitlbee/bitlbee.initd b/main/bitlbee/bitlbee.initd
new file mode 100644
index 000000000..b0ba0cc81
--- /dev/null
+++ b/main/bitlbee/bitlbee.initd
@@ -0,0 +1,29 @@
+#!/sbin/runscript
+
+name=bitlbee
+daemon=/usr/sbin/$name
+
+. /etc/conf.d/$name
+
+depend() {
+ need net
+ after firewall
+}
+
+start() {
+ ebegin "Starting ${name}"
+ start-stop-daemon --start --quiet \
+ --pidfile /var/run/${name}.pid \
+ --chuid nobody:nobody \
+ --exec ${daemon} -- ${PORT} ${OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ${name}"
+ start-stop-daemon --stop --quiet \
+ --pidfile /var/run/$name.pid \
+ --exec ${daemon}
+ eend $?
+}
+
diff --git a/main/bitlbee/bitlbee.post-install b/main/bitlbee/bitlbee.post-install
new file mode 100644
index 000000000..d962fdcd9
--- /dev/null
+++ b/main/bitlbee/bitlbee.post-install
@@ -0,0 +1,4 @@
+#!/bin/sh
+mkdir -p /var/lib/bitlbee
+chown nobody:nobody /var/lib/bitlbee
+