updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / viewvc / PKGBUILD
blobd3883848cd990a33e6b378a771f1635f3306c7d0
1 # Contributor: Claudio Riva <firetux83@gmail.com>
3 pkgname=viewvc
4 pkgver=1.1.8
5 pkgrel=1
6 pkgdesc="Web-based Version Control Repository Browsing"
7 url="http://viewvc.tigris.org/"
8 license=('custom:ViewVC')
9 arch=('i686' 'x86_64')
10 depends=('python2' 'diffutils')
11 makedepends=('subversion' 'cvs' 'rcs')
12 backup=(usr/share/viewvc/viewvc.conf)
13 install=$pkgname.install
14 source=(http://viewvc.tigris.org/files/documents/3330/48659/$pkgname-$pkgver.tar.gz)
15 md5sums=('ed4c74b85d6eac69c72ae2554326f56a')
17 build() {
18    cd $startdir/src/$pkgname-$pkgver
19    
20    sed -i "s@/usr/bin/env python@/usr/bin/env python2@g" viewvc-install
21    sed -i "s@DESTDIR = None@DESTDIR = \"$startdir/pkg/\"@g" viewvc-install
22    sed -i "s@ROOT_DIR = None@ROOT_DIR = \"/usr/share/$pkgname\"@g" viewvc-install
23    ./viewvc-install
24    install -D -m 755 $startdir/pkg/usr/share/$pkgname/bin/cgi/query.cgi $startdir/pkg/srv/httpd/cgi-bin/query.cgi
25    install -D -m 755 $startdir/pkg/usr/share/$pkgname/bin/cgi/viewvc.cgi $startdir/pkg/srv/httpd/cgi-bin/viewvc.cgi
26    sed -i "s@#rcs_path = /usr/bin/@rcs_path = /usr/bin/@g" $startdir/pkg/usr/share/viewvc/viewvc.conf
27    sed -i "s@mime_types_file = /usr/local/apache/conf/mime.types@mime_types_file = /etc/httpd/conf/mime.types@g" $startdir/pkg/usr/share/viewvc/viewvc.conf
28    install -Dm644 LICENSE.html $startdir/pkg/usr/share/licenses/$pkgname/LICENSE.html