aboutsummaryrefslogtreecommitdiffstats
path: root/main/privoxy/APKBUILD
blob: bba3c2f88f0d3873a52290956f0458b7afd5ae9d (plain) (blame)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=privoxy
pkgver=3.0.31
pkgrel=0
pkgdesc="web proxy with advanced filtering capabilities"
url="https://www.privoxy.org"
arch="all"
license="GPL-2.0-or-later"
pkgusers="privoxy"
pkggroups="privoxy"
makedepends="autoconf automake pcre-dev zlib-dev coreutils"
install="privoxy.pre-install"
subpackages="$pkgname-doc $pkgname-openrc"
source="https://downloads.sourceforge.net/ijbswa/privoxy-$pkgver-stable-src.tar.gz
	$pkgname.initd
	$pkgname.logrotate
	privoxy-alpine.patch
	"
options="!check" # No test suite
builddir="$srcdir/$pkgname-$pkgver-stable"

prepare() {
	update_config_sub
	default_prepare

	aclocal && autoheader && autoconf
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--localstatedir=/var/ \
		--enable-zlib \
		--enable-dynamic-pcre \
		--with-user=privoxy \
		--with-group=privoxy \
		--sysconfdir=/etc/privoxy \
		--docdir=/usr/share/doc/$pkgname
	make
}

package() {
	make DESTDIR="$pkgdir" install

	rm -f "$pkgdir"/var/log/privoxy/*

	install -D -m755 "$srcdir"/privoxy.initd "$pkgdir"/etc/init.d/privoxy
	install -D -m644 "$srcdir"/privoxy.logrotate \
		"$pkgdir"/etc/logrotate.d/privoxy

	find "$pkgdir"/etc/privoxy/ -type d | xargs chmod 770
	find "$pkgdir"/etc/privoxy/ -type f | xargs chmod 660

	chown -R privoxy:privoxy "$pkgdir"/var/log/privoxy \
		"$pkgdir"/etc/privoxy
}

sha512sums="0bea9973ac22e594a959452390c8612605dbf1fd55151632d35ecc7fe0ef9ca87cc1694a8bcb0511467445ec414b721b9d33651d917b2a8083768d8905ec68ed  privoxy-3.0.31-stable-src.tar.gz
346bda3a2108547569af3397c77e092c54fa0c20bc6d3bb1d4c202b4e2b8d9c13018eab0a326cd9632310ec8052600ee7db4b6011610faec386c399cdd01af9c  privoxy.initd
118caaeac3aba751584c5bdfc737bf5bfeddf1a62fda1f44bcd4654ae2e33183bc1ce6fc66d4a1bdd79766e42e669b1615a6d46d528a1bd49cabdf98385a3bb9  privoxy.logrotate
0220785fff0b34b75e3c8cecbeb302e0137e96039e0663ae44d7450e334a3c1d742c2760de55d52817fb9ed2efb19f505e1fb7406d055b387b7b084f5f52011f  privoxy-alpine.patch"