summaryrefslogtreecommitdiff
path: root/community/tinyproxy/PKGBUILD
blob: f2ab10d98d7f63a45c8c5e6c05bdbdb5c6b7a208 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# $Id: PKGBUILD 55575 2011-09-14 10:47:03Z lfleischer $
# Maintainer: Lukas Fleischer <archlinux at cryptocrack dot de>
# Contributor: Andrea Zucchelli <zukka77@gmail.com>

pkgname=tinyproxy
pkgver=1.8.3
pkgrel=1
pkgdesc='A light-weight HTTP proxy daemon for POSIX operating systems.'
arch=('i686' 'x86_64')
url='https://banu.com/tinyproxy/'
license=('GPL')
makedepends=('asciidoc')
backup=('etc/tinyproxy/tinyproxy.conf')
source=("https://banu.com/pub/${pkgname}/1.8/${pkgname}-${pkgver}.tar.bz2"
        'tinyproxy')
md5sums=('292ac51da8ad6ae883d4ebf56908400d'
         '464b5d60b1c9cbae26367fe2337c2d77')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  ./configure --prefix=/usr --sysconfdir=/etc/tinyproxy --localstatedir=/var
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  make DESTDIR="${pkgdir}" install
  install -Dm0755 "${srcdir}/tinyproxy" "${pkgdir}/etc/rc.d/tinyproxy"

  install -dm0755 -o nobody -g nobody "${pkgdir}/var/log/${pkgname}"

  # Provide sane defaults
  sed -i '/^#Listen/a\Listen 127.0.0.1' "${pkgdir}/etc/tinyproxy/tinyproxy.conf"
}