From 62ce2d47a819bb21d3e462fc5e56cdfde3aab621 Mon Sep 17 00:00:00 2001 From: Nicolás Reynolds Date: Tue, 12 Mar 2013 16:04:04 -0300 Subject: Upgraded, it was missing on repos --- pcr/opentracker/PKGBUILD | 67 +++++++++++++++++++++++++++++++++++++ pcr/opentracker/license.txt | 2 ++ pcr/opentracker/opentracker.install | 17 ++++++++++ pcr/opentracker/opentracker.rc.d | 37 ++++++++++++++++++++ pcr/opentracker/opentracker.service | 11 ++++++ 5 files changed, 134 insertions(+) create mode 100644 pcr/opentracker/PKGBUILD create mode 100644 pcr/opentracker/license.txt create mode 100644 pcr/opentracker/opentracker.install create mode 100644 pcr/opentracker/opentracker.rc.d create mode 100644 pcr/opentracker/opentracker.service (limited to 'pcr/opentracker') diff --git a/pcr/opentracker/PKGBUILD b/pcr/opentracker/PKGBUILD new file mode 100644 index 000000000..d2b9a3703 --- /dev/null +++ b/pcr/opentracker/PKGBUILD @@ -0,0 +1,67 @@ +# Contributor: Pierre Schmitz +# Maintainer: Jonas Heinrich + +pkgname=opentracker +pkgver=20130312 +pkgrel=1 +pkgdesc='An open and free bittorrent tracker (open mode)' +arch=('i686' 'x86_64' 'mips64el') +url='http://erdgeist.org/arts/software/opentracker/' +license=('custom:Beer' 'GPL') +makedepends=('libowfat' 'cvs') +depends=('bash' 'zlib') +backup=('etc/opentracker/config') +source=("http://repo.parabolagnulinux.org/other/${pkgname}-${pkgver}.tar.gz"{,.sig} +'opentracker.service' +'license.txt') +md5sums=('64956fd9bc7b453b4862b8ba15a27511' + '0217a2aeaee2b75017c13cdf86a245f2' + '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 opentracker service + mkdir -p "$pkgdir/usr/lib/systemd/system/" + install -m 644 "$srcdir/opentracker.service" "$pkgdir/usr/lib/systemd/system/" +} diff --git a/pcr/opentracker/license.txt b/pcr/opentracker/license.txt new file mode 100644 index 000000000..ff1bb40f5 --- /dev/null +++ b/pcr/opentracker/license.txt @@ -0,0 +1,2 @@ +This software was written by Dirk Engling +It is considered beerware. Prost. Skol. Cheers or whatever. diff --git a/pcr/opentracker/opentracker.install b/pcr/opentracker/opentracker.install new file mode 100644 index 000000000..59f6f6ebe --- /dev/null +++ b/pcr/opentracker/opentracker.install @@ -0,0 +1,17 @@ +post_install() { + cat </dev/null + if [ $? -gt 0 ]; then + stat_fail + else + rm_daemon opentracker + stat_done + fi + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac diff --git a/pcr/opentracker/opentracker.service b/pcr/opentracker/opentracker.service new file mode 100644 index 000000000..5f1b887ea --- /dev/null +++ b/pcr/opentracker/opentracker.service @@ -0,0 +1,11 @@ +[Unit] +Description=OpenTracker Daemon +After=network.target + +[Service] +User=nobody +ExecStart=/usr/bin/opentracker -f /etc/opentracker/config +ExecStop=/bin/kill -INT $MAINPID + +[Install] +WantedBy=multi-user.target -- cgit v1.2.3