# Contributor: Natanael Copa # Maintainer: Natanael Copa pkgname=libproxy pkgver=0.4.7 pkgrel=1 pkgdesc="A library handling all the details of proxy configuration" url="http://code.google.com/p/libproxy/" arch="all" license="LGPLv2+" depends= depends_dev="zlib-dev" makedepends="cmake python-dev $depends_dev" install="" subpackages="$pkgname-dev $pkgname-bin py-$pkgname:py" source="http://libproxy.googlecode.com/files/libproxy-$pkgver.tar.gz libproxy-0.4.7-unistd.patch" _builddir="$srcdir"/libproxy-$pkgver prepare() { local i cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { cd "$_builddir" cmake \ -DCMAKE_INSTALL_PREFIX=/usr \ -DLIBEXEC_INSTALL_DIR=lib \ -DMODULE_INSTALL_DIR=/usr/lib/libproxy/$pkgver/modules \ -DWITH_PERL=OFF \ ./ || return 1 make || return 1 } package() { cd "$_builddir" make DESTDIR="$pkgdir" install || return 1 } dev() { default_dev mkdir -p "$subpkgdir"/usr/share mv "$pkgdir"/usr/share/cmake "$subpkgdir"/usr/share/ } bin() { pkgdesc="Binary to test libproxy" mkdir -p "$subpkgdir"/usr mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ } py() { pkgdesc="Binding for libproxy and python" mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/ } md5sums="509e03a488a61cd62bfbaf3ab6a2a7a5 libproxy-0.4.7.tar.gz e90c03f296e553ace347b46f4fea3625 libproxy-0.4.7-unistd.patch"