1 # Maintainer: Jarek Sedlacek <jarek @ nbcs.rutgers.edu>
6 pkgdesc="nzb downloader and post processor"
7 url="http://www.hellanzb.com"
8 depends=('python2' 'twisted-web2' 'par2cmdline' 'unrar')
9 optdepends=('pyopenssl: for SSL')
10 source=("http://distfiles.macports.org/python/$pkgname-$pkgver.tar.gz" \
11 "hellanzb.rc" "hellanzb.conf.d" "whitespace-fix.diff" "python_26_fixes.diff" "version.diff" "fileno.diff")
12 arch=('i686' 'x86_64')
14 install=hellanzb.install
15 backup=('etc/conf.d/hellanzb')
18 cd $startdir/src/$pkgname-$pkgver
20 # change the configuration directories searched from /usr/etc to /etc and
21 # from ./etc to ~/.config
23 -e "\|confDirs = |s|sys.prefix|'/'|" \
24 -e "\|confDirs\.append|s|join(os.getcwd(), *'etc|expanduser('~/.config|" \
25 Hellanzb/Core.py || return 1
27 # fix the problem with whitespace in the group name
28 patch -p1 < ../whitespace-fix.diff || return 1
29 patch -p0 < ../python_26_fixes.diff || return 1
30 patch -p0 < ../version.diff || return 1
31 patch -p0 < ../fileno.diff || return 1
33 python2 ./setup.py install --root=$startdir/pkg || return 1
35 # move /usr/etc to /etc
36 mv $startdir/pkg/usr/etc $startdir/pkg/
38 install -D -m644 LICENSE $startdir/pkg/usr/share/licenses/$pkgname/LICENSE
40 # install the rc scripts
42 mkdir -p $startdir/pkg/etc/{rc.d,conf.d}
43 install -D -m755 hellanzb.rc $startdir/pkg/etc/rc.d/hellanzb
44 install -D -m644 hellanzb.conf.d $startdir/pkg/etc/conf.d/hellanzb
47 md5sums=('d3510c6b1b2c7b935332a469fdc8e7e2'
48 '85a0e75581781a4854bdc4903118773b'
49 '0bda37be41e3d0662bd8cdb0fdff6a20'
50 'be7ccbed81e98c43c59a10ab64992f7c'
51 '86888247312f7b95df9c914e920e04b4'
52 '74524bbc8b2c3a7524312af374bf3036'
53 'bce7219444aff088787227cc1c7f6f2f')