# Contributor: Francesco Colista # Maintainer: Francesco Colista pkgname=dnscrypt-proxy pkgver=1.5.0 pkgrel=0 pkgdesc="A tool for securing communications between a client and a DNS resolver" url="http://dnscrypt.org/" arch="all" license="custom" depends="" depends_dev="libsodium-dev" makedepends="$depends_dev" install="$pkgname.pre-install" pkgusers=dnscrypt pkggroups=dnscrypt subpackages="$pkgname-doc $pkgname-setup" source="http://download.dnscrypt.org/$pkgname/$pkgname-$pkgver.tar.bz2 $pkgname.initd $pkgname.confd $pkgname.setup " _builddir="$srcdir"/$pkgname-$pkgver build() { cd "$_builddir" CFLAGS="$CFLAGS -fPIC" ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr \ || return 1 make || return 1 } package() { cd "$_builddir" make DESTDIR=$pkgdir install || return 1 mkdir -p "$pkgdir"/var/log/$pkgname mkdir -p "$pkgdir"/var/run/$pkgname mkdir -p "$pkgdir"/var/empty mkdir -p $pkgdir/usr/share/licenses/$pkgname install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname chown dnscrypt "$pkgdir"/var/log/$pkgname chown dnscrypt "$pkgdir"/var/run/$pkgname chown dnscrypt "$pkgdir"/var/empty rm -rf $pkgdir/usr/lib/*.la install -m 644 COPYING $pkgdir/usr/share/licenses/$pkgname } setup() { arch="noarch" pkgdesc="Script for setting up DNSCrypt Proxy" depends="sed wget $pkgname" mkdir -p "$subpkgdir"/sbin install -m755 -D "$srcdir"/$pkgname.setup "$subpkgdir"/sbin/setup-dnscrypt } md5sums="7811ae38c6cd2be06dd024f3f73bcc9e dnscrypt-proxy-1.5.0.tar.bz2 6ca1f01a62ca9e937851986560709a61 dnscrypt-proxy.initd 77b800da6d8cdf6316afacbff740b09a dnscrypt-proxy.confd 2f6edba8ee4093ee02f6660744e96558 dnscrypt-proxy.setup" sha256sums="dd1a09baff5685cf939c429ba0258f66a79d464bc5ac130d8d30e667fb8ee3b2 dnscrypt-proxy-1.5.0.tar.bz2 aa2b83b1944ba5f47ee5b7f2cf3cf63fbef4735753a2daf83fea3bf0ea51a7a3 dnscrypt-proxy.initd 36bd49d3fdada3ed8fc6abae7a8dd40a1f7a0aabf0eb1311698030b7ec710699 dnscrypt-proxy.confd d9db363a07c8284fa0cb38988a19d22240112e8d28208dec609918ab5f495b37 dnscrypt-proxy.setup" sha512sums="d01f3ae279967f52d7bcfea515d4df3d42f5548b2f3a4ef1e0036deef7d7ed1c2808c41a0235bad19cbb536287b1548b43539ef3836da29b3a276e209fa3efb2 dnscrypt-proxy-1.5.0.tar.bz2 5ad36161fc44d9c8c86a13e20d4d5fa0be81b317097bf1c092aab1e1e307021a8b6f1a92dbf2bec5fb7c534b59cf926235ea507fa6b4ccd2974ac2e3b7baa257 dnscrypt-proxy.initd 8cd2d40c1f465a3b26aa934fe2103650beba9504676faca3ccc9ee2b5bad940e561b3dd201d84c380bfdada72cacbe4862fc1315a4bd44fd7c56ef4f19a884f9 dnscrypt-proxy.confd 0ad9dacf39beebd2364165e45d2f76de39cb7e4b51233ac20eaefb96e6e3c6f3bac192126035f0979b6e2108e01ceb32cf618a3b182d1d5d38b46ecd48453881 dnscrypt-proxy.setup"