desktop/tor/PKGBUILD

55 lines
1.6 KiB
Bash
Raw Normal View History

# Maintainer: UtG <utg[dot]chakra.linux[at]gmail[dot]com>
2013-01-15 02:23:38 +08:00
# contributor Giuseppe Calà <jiveaxe@gmail.com>
pkgname=tor
2014-12-09 00:01:56 +08:00
pkgver=0.2.5.10
2013-01-15 02:23:38 +08:00
pkgrel=1
pkgdesc="Anonymizing overlay network"
2013-01-15 02:23:38 +08:00
arch=('x86_64')
url="http://www.torproject.org/"
license=('BSD')
2014-12-09 00:01:56 +08:00
depends=('openssl' 'libevent' 'torsocks' 'bash')
backup=('etc/tor/torrc' 'etc/tor/torrc-dist' 'etc/tor/tor-torsocks.conf')
categories=('network')
2012-09-27 03:15:15 +08:00
install=${pkgname}.install
2014-01-01 01:38:17 +08:00
option=('!docs' '!emptydirs')
2012-09-27 03:15:15 +08:00
source=("http://www.torproject.org/dist/${pkgname}-${pkgver}.tar.gz"
2014-12-09 00:01:56 +08:00
"http://www.torproject.org/dist/${pkgname}-${pkgver}.tar.gz.asc"
2012-09-27 03:15:15 +08:00
'torrc'
'tor.conf.d'
'tor.service')
2014-12-09 00:01:56 +08:00
md5sums=('4bde375229a7a7f77c0596ae05556527'
'SKIP'
'bb7b85a70c2997a3e05f023c97768f5e'
2013-01-15 02:23:38 +08:00
'f656f3e93f0c2ed46464d9b784876dbc'
'98901f7dfa85b352b806ba7b0d66b7d0')
build() {
2012-09-27 03:15:15 +08:00
cd "${srcdir}/${pkgname}-${pkgver}"
2013-01-15 02:23:38 +08:00
./configure --prefix=/usr \
2012-09-27 03:15:15 +08:00
--sysconfdir=/etc \
--localstatedir=/var
2013-01-15 02:23:38 +08:00
make
}
package() {
2012-09-27 03:15:15 +08:00
cd "${srcdir}/${pkgname}-${pkgver}"
2013-01-15 02:23:38 +08:00
2012-09-27 03:15:15 +08:00
make DESTDIR="${pkgdir}" install
2013-01-15 02:23:38 +08:00
install -dm0700 "${pkgdir}/var/lib/tor"
2012-09-27 03:15:15 +08:00
# Install config files
mv "${pkgdir}/etc/tor/torrc.sample" "${pkgdir}/etc/tor/torrc-dist"
2013-01-15 02:23:38 +08:00
install -Dm0644 "${srcdir}/torrc" "${pkgdir}/etc/tor/torrc"
2012-09-27 03:15:15 +08:00
install -Dm0644 "${srcdir}/tor.conf.d" "${pkgdir}/etc/conf.d/tor"
2013-01-15 02:23:38 +08:00
2012-09-27 03:15:15 +08:00
# Install systemd service file
2013-01-15 02:23:38 +08:00
install -Dm0644 "${srcdir}/tor.service" "${pkgdir}/usr/lib/systemd/system/tor.service"
2012-09-27 03:15:15 +08:00
2013-01-15 02:23:38 +08:00
# Install license
install -Dm0644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}