summaryrefslogtreecommitdiff
path: root/community/ejabberd/PKGBUILD
blob: 6ab28551ad97b382534797f4c19539d501e65764 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# $Id: PKGBUILD 70983 2012-05-21 13:12:40Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Jeff 'codemac' Mickey <jeff@archlinux.org>
# Contributor: Alexander Rødseth <rodseth@gmail.com>

pkgname=ejabberd
pkgver=2.1.11
pkgrel=1
pkgdesc="Jabber server written in Erlang"
arch=('x86_64' 'i686')
url="http://www.ejabberd.im/"
license=("GPL")
depends=('expat' 'openssl' 'zlib' 'erlang' 'pam' 'iproute2')
backup=(etc/ejabberd/ejabberd.cfg etc/logrotate.d/ejabberd)
install=$pkgname.install
source=("http://www.process-one.net/downloads/ejabberd/${pkgver/_/-}/ejabberd-${pkgver}.tgz"
        "$pkgname.logrotate"
        "$pkgname")
sha256sums=('9dc2e5889e919a7d51f2b95b83da835116631db81550a115c02e71909ad932be'
            '31780cac78736d285e46f445f8c8463a70f2aeb2683280c259129db11832ddd2'
            '93f8f9a8751b9e982b332f74e71f766c3c9c4818876991cadef08fe140b83ca6')
sha256sums=('bb5560a8cc77c46238a67bd6e8fd116c960be7f4c135346cda96da548d20ef6e'
            '31780cac78736d285e46f445f8c8463a70f2aeb2683280c259129db11832ddd2'
            '93f8f9a8751b9e982b332f74e71f766c3c9c4818876991cadef08fe140b83ca6')
sha256sums=('91d5c10e64f9faa60c345c68304746f493d71f82723302955d40d6619e3d87de'
            '31780cac78736d285e46f445f8c8463a70f2aeb2683280c259129db11832ddd2'
            '93f8f9a8751b9e982b332f74e71f766c3c9c4818876991cadef08fe140b83ca6')

build() {
  cd "$srcdir/$pkgname-$pkgver/src"

  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
    --enable-pam --enable-odbc
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver/src"

  make DESTDIR="$pkgdir" install
  install -D -m 0755 "$srcdir/$pkgname" "$pkgdir/etc/rc.d/$pkgname"
  install -d "$pkgdir/var/spool/$pkgname"
  install -d "$pkgdir/var/lib/$pkgname"
  install -D -m0644 "$srcdir/$pkgname.logrotate" \
    "$pkgdir/etc/logrotate.d/$pkgname"
  chmod ug+r "$pkgdir/etc/$pkgname/"*
  rm -rf "$pkgdir/var/lock"
}

# vim:set ts=2 sw=2 et: