diff options
author | Omar Vega Ramos <ovruni@gnu.org.pe> | 2015-05-21 18:49:29 -0500 |
---|---|---|
committer | Omar Vega Ramos <ovruni@gnu.org.pe> | 2015-05-21 18:49:29 -0500 |
commit | 33975c6154aea6e2ce2ef55140ef04b4b6815651 (patch) | |
tree | d69af538fd2974c98aa8752977646feda9a36c38 | |
parent | de855f961f2b80778bc1a3fbcd8c898ee5bf792f (diff) | |
download | abslibre-33975c6154aea6e2ce2ef55140ef04b4b6815651.tar.gz abslibre-33975c6154aea6e2ce2ef55140ef04b4b6815651.tar.bz2 abslibre-33975c6154aea6e2ce2ef55140ef04b4b6815651.zip |
opentracker-git: add new package to [pcr]
-rw-r--r-- | pcr/opentracker-git/PKGBUILD | 117 | ||||
-rw-r--r-- | pcr/opentracker-git/license.txt | 8 | ||||
-rw-r--r-- | pcr/opentracker-git/opentracker.service (renamed from pcr/opentracker/opentracker.service) | 0 | ||||
-rw-r--r-- | pcr/opentracker/PKGBUILD | 67 | ||||
-rw-r--r-- | pcr/opentracker/license.txt | 2 | ||||
-rw-r--r-- | pcr/opentracker/opentracker.install | 17 | ||||
-rw-r--r-- | pcr/opentracker/opentracker.rc.d | 37 |
7 files changed, 125 insertions, 123 deletions
diff --git a/pcr/opentracker-git/PKGBUILD b/pcr/opentracker-git/PKGBUILD new file mode 100644 index 000000000..f5ef91aef --- /dev/null +++ b/pcr/opentracker-git/PKGBUILD @@ -0,0 +1,117 @@ +# Maintainer (Arch): TheCreeper <loxoko@gmail.com> +# Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe> + +pkgname=opentracker-git +pkgver=r583.6c60309 +pkgrel=1 +pkgdesc="Opentracker is a open and free bittorrent tracker project. It aims for minimal resource usage and is intended to run at your wlan router." +arch=('i686' 'x86_64') +url="http://erdgeist.org/arts/software/opentracker/" +license=('custom') +depends=('libowfat') +makedepends=( + 'git' + #'cvs' + 'make' + 'gcc' + 'gcc-libs' + 'dietlibc' +) +backup=("etc/opentracker/config") +source=( + 'opentracker.service' + 'license.txt' + "$pkgname"::'git://erdgeist.org/opentracker') +sha1sums=( + 'f623a45a0722bdc007f1d4b303ff6e3913281953' + '7cd200ee8ee89ddbd302dbbf63b6993bc51d4e3e' + 'SKIP') + +pkgver() { + cd "$srcdir/$pkgname" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +build() { + + ## BEWARE: + ## I had problems compiling this on arm using the new verson of GCC. + + #### + ## Build Libowfat + #### + + ## Pull in libowfat + #msg "Pulling in libowfat" + #cvs -d :pserver:cvs@cvs.fefe.de:/cvs -z9 co libowfat + + ## Compile libowfat + #msg "Compiling libowfat" + #cd "$srcdir/libowfat" + #make + + #### + ## Build Opentracker + #### + + #### + ## The following is a list of compile time options + ## Add them to the 'FEATURES' option of the make command below + + #DWANT_V6 > Compile in IPV6 only support. + + ## Only one of the following accesslist options can be used. + #DWANT_ACCESSLIST_BLACK > Compile in a blacklist of allowed torrents. + #DWANT_ACCESSLIST_WHITE > Compile in a whitelist of allowed torrents. + + #FDWANT_SYNC_LIVE > Compile in support for running in clusters. + #DWANT_IP_FROM_QUERY_STRING > Experimental or old feature. No idea what this does. + #DWANT_COMPRESSION_GZIP > Compile in support for GZIP. This is used when downloading scrapes. + #DWANT_COMPRESSION_GZIP_ALWAYS > Always compress scrapes using GZIP before serving them to clients. + #DWANT_LOG_NETWORKS > Experimental or old feature. No idea what this does. + #DWANT_RESTRICT_STATS > Compile in support for restricting tracker stats based on IP. Can be configured in the configuration file. + #DWANT_IP_FROM_PROXY > Experimental or old feature. No idea what this does. + #DWANT_FULLLOG_NETWORKS > Experimental or old feature. No idea what this does. + #DWANT_LOG_NUMWANT > Experimental or old feature. No idea what this does. + #DWANT_MODEST_FULLSCRAPES > Experimental or old feature. No idea what this does. + #DWANT_SPOT_WOODPECKER > Experimental or old feature. No idea what this does. + #DWANT_SYSLOGS > Experimental or old feature. No idea what this does. + #DWANT_DEV_RANDOM > Experimental or old feature. No idea what this does. + #DWANT_FULLSCRAPE > Compile in support for querying opentracker for all tracked torrents. Defualt. Change Makefile to compile out this support. + + #D_DEBUG_HTTPERROR > This should add in support for serving errors to clients when pages like 127.0.0.1:6969/random are accessed which are not used by opentracker. + + msg "Compiling Opentracker" + cd "$srcdir/opentracker-git/" + + make LIBOWFAT_HEADERS="/usr/include" \ + LIBOWFAT_LIBRARY="/usr/lib" \ + #LIBOWFAT_HEADERS="../libowfat" \ + #LIBOWFAT_LIBRARY="../libowfat" \ + FEATURES="-DWANT_SYSLOGS -DDEBUG_HTTPERROR" \ + CC="/opt/diet/bin/diet gcc" +} + +package() { + + msg "Preparing the package" + + cd "$srcdir/" + + install -d $pkgdir/usr/bin/ + install -m 755 opentracker-git/opentracker $pkgdir/usr/bin/ + + install -d $pkgdir/usr/lib/systemd/system + install -m 755 opentracker.service $pkgdir/usr/lib/systemd/system/ + + install -d $pkgdir/etc/opentracker + install -m 644 opentracker-git/opentracker.conf.sample $pkgdir/etc/opentracker/config + + install -d $pkgdir/usr/share/doc/opentracker/ + install -m 644 opentracker-git/opentracker.conf.sample $pkgdir/usr/share/doc/opentracker/config + + install -d $pkgdir/usr/share/licenses/opentracker/ + install -m 644 license.txt $pkgdir/usr/share/licenses/opentracker/ + + msg "Finished" +}
\ No newline at end of file diff --git a/pcr/opentracker-git/license.txt b/pcr/opentracker-git/license.txt new file mode 100644 index 000000000..ebbaa7b0f --- /dev/null +++ b/pcr/opentracker-git/license.txt @@ -0,0 +1,8 @@ +/* + * ---------------------------------------------------------------------------- + * "THE BEER-WARE LICENSE" (Revision 42): + * <erdgeist@erdgeist.org> wrote this file. As long as you retain this notice you + * can do whatever you want with this stuff. If we meet some day, and you think + * this stuff is worth it, you can buy me a beer in return Poul-Henning Kamp + * ---------------------------------------------------------------------------- + */
\ No newline at end of file diff --git a/pcr/opentracker/opentracker.service b/pcr/opentracker-git/opentracker.service index 5f1b887ea..5f1b887ea 100644 --- a/pcr/opentracker/opentracker.service +++ b/pcr/opentracker-git/opentracker.service diff --git a/pcr/opentracker/PKGBUILD b/pcr/opentracker/PKGBUILD deleted file mode 100644 index 2834866aa..000000000 --- a/pcr/opentracker/PKGBUILD +++ /dev/null @@ -1,67 +0,0 @@ -# Contributor (Arch): Pierre Schmitz <pierre@archlinux.de> -# Maintainer (Arch): Jonas Heinrich <onny@project-insanity.org> - -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.parabola.nu/other/${pkgname}/${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 deleted file mode 100644 index ff1bb40f5..000000000 --- a/pcr/opentracker/license.txt +++ /dev/null @@ -1,2 +0,0 @@ -This software was written by Dirk Engling <erdgeist@erdgeist.org> -It is considered beerware. Prost. Skol. Cheers or whatever. diff --git a/pcr/opentracker/opentracker.install b/pcr/opentracker/opentracker.install deleted file mode 100644 index 59f6f6ebe..000000000 --- a/pcr/opentracker/opentracker.install +++ /dev/null @@ -1,17 +0,0 @@ -post_install() { - cat <<EOM - - Please be aware this package is built without accesslist support. Any - torrent announced to it will be tracked. - - If you want this features you'll have to rebuild this package. There're - instructions on the PKGBUILD. - - For more info check: http://erdgeist.org/arts/software/opentracker/ - -EOM -} - -post_upgrade() { - post_install -} diff --git a/pcr/opentracker/opentracker.rc.d b/pcr/opentracker/opentracker.rc.d deleted file mode 100644 index b1aa34c14..000000000 --- a/pcr/opentracker/opentracker.rc.d +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/bash - -# general config -. /etc/rc.conf -. /etc/rc.d/functions - -PID=`pidof -o %PPID /usr/bin/opentracker` - -case "$1" in - start) - stat_busy "Starting opentracker Daemon" - [ -z "$PID" ] && su nobody -s /bin/sh -c "/usr/bin/opentracker -f /etc/opentracker/config&" - if [ $? -gt 0 ]; then - stat_fail - else - add_daemon opentracker - stat_done - fi - ;; - stop) - stat_busy "Stopping opentracker Daemon" - [ ! -z "$PID" ] && kill $PID &>/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 |