blob: 2826a21ef7b94d13b794223d2bd517c9c54365c1 (
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
# Contributor: Pierre Schmitz <pierre@archlinux.de>
# Maintainer: Jonas Heinrich <onny@project-insanity.org>
pkgname=opentracker
pkgver=20120911
pkgrel=2
pkgdesc='An open and free bittorrent tracker (open mode)'
arch=('i686' 'x86_64')
url='http://erdgeist.org/arts/software/opentracker/'
license=('custom:Beer' 'GPL')
makedepends=('libowfat' 'cvs')
depends=('bash' 'zlib')
backup=('etc/opentracker/config')
source=('opentracker.rc'
'opentracker.service'
'license.txt')
md5sums=('390bde9d010e79ab1309c02dcf9972e8'
'3c638b71d5ecb65fb7964796975b2078'
'865211941e882c0aff5d36a22ac9efaa')
_cvsroot=':pserver:anoncvs@cvs.erdgeist.org:/home/cvsroot'
_cvsmod='opentracker'
mksource() {
pushd "${srcdir}"
msg 'Connecting to CVS server....'
if [ -d ${_cvsmod}/CVS ]; then
cd ${_cvsmod}
cvs -z3 update -d
else
cvs -z3 -d ${_cvsroot} co -f ${_cvsmod}
cd ${_cvsmod}
fi
msg 'CVS checkout done or server timeout'
popd
tar czf ${pkgname}-${pkgver}.tar.gz ${_cvsmod}/
}
build() {
cd "${srcdir}/${_cvsmod}"
msg 'Starting make...'
sed -e 's|# tracker.rootdir /usr/local/etc/opentracker|tracker.rootdir /etc/opentracker|' \
-e 's|# access.stats 192.168.0.23|access.stats 127.0.0.1|' \
-i opentracker.conf.sample
# See Makefile for available features
make PREFIX=/usr \
LIBOWFAT_HEADERS=/usr/includes \
LIBOWFAT_LIBRARY=/usr/lib \
FEATURES="-DWANT_SYSLOGS -DDEBUG_HTTPERROR"
}
package(){
cd "${srcdir}/${_cvsmod}"
install -D -m 755 opentracker $pkgdir/usr/bin/opentracker
install -D -m 644 opentracker.conf.sample $pkgdir/etc/opentracker/config
install -D -m 644 $srcdir/license.txt $pkgdir/usr/share/licenses/opentracker/license.txt
# create /etc/rc.d/opentracker
mkdir -p "$pkgdir/etc/rc.d/"
install -m 755 "$srcdir/opentracker.rc" "$pkgdir/etc/rc.d/opentracker"
# Create opentracker service
mkdir -p "$pkgdir/usr/lib/systemd/system/"
install -m 644 "$srcdir/opentracker.service" "$pkgdir/usr/lib/systemd/system/"
}
|