PKGBUILD 1.21 KB
Newer Older
1 2 3 4 5 6 7 8 9
#
# Chakra Packages for Chakra, part of chakra-project.org
#
# contributor (x86_64): Giuseppe Calà <jiveaxe@gmail.com>

# include global config
source ../_buildscripts/${current_repo}-${_arch}-cfg.conf

pkgname=tor
Neophytos's avatar
Neophytos committed
10
pkgver=0.2.2.35
Anke's avatar
Anke committed
11
pkgrel=1
12 13 14 15 16 17 18 19 20 21
pkgdesc="Anonymizing overlay network"
arch=('i686' 'x86_64')
url="http://www.torproject.org/"
license=('BSD')
depends=('openssl' 'libevent' 'tsocks' 'bash')
backup=('etc/tor/torrc' 'etc/tor/torrc-dist' 'etc/tor/tor-tsocks.conf')
install=tor.install
source=(http://www.torproject.org/dist/${pkgname}-${pkgver}.tar.gz
	'tor.conf'
	'tor.rc')
Neophytos's avatar
Neophytos committed
22
md5sums=('dcecf699c4b929319d5f1ce0358d4835'
23 24 25 26 27 28 29 30
         'c97998c760c4351f12ad41d514071a9b'
         '23348b8e3b38c6ed2a45b4be42a7de8e')

build() {
  cd ${srcdir}/${pkgname}-${pkgver}
  
  ./configure --prefix=/usr \
    --sysconfdir=/etc \
abveritas's avatar
abveritas committed
31 32
    --localstatedir=/var 
  make 
33 34 35 36
}

package() {
  cd ${srcdir}/${pkgname}-${pkgver}
abveritas's avatar
abveritas committed
37
  make DESTDIR="$pkgdir" install 
38

abveritas's avatar
abveritas committed
39
  install -d ${pkgdir}/var/lib/tor 
40
  
abveritas's avatar
abveritas committed
41 42 43
  mv "$pkgdir/etc/tor/torrc.sample" "$pkgdir/etc/tor/torrc-dist" 
  install -D -m644 "$srcdir/tor.conf" "$pkgdir/etc/tor/torrc" 
  install -D -m755 "$srcdir/tor.rc" "$pkgdir/etc/rc.d/tor" 
44
  
abveritas's avatar
abveritas committed
45
  install -Dm644 LICENSE "$pkgdir/usr/share/licenses/${pkgname}/LICENSE" 
46
}