diff options
Diffstat (limited to 'libre/python-reportlab-libre/PKGBUILD')
-rw-r--r-- | libre/python-reportlab-libre/PKGBUILD | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/libre/python-reportlab-libre/PKGBUILD b/libre/python-reportlab-libre/PKGBUILD new file mode 100644 index 000000000..2fc4ee836 --- /dev/null +++ b/libre/python-reportlab-libre/PKGBUILD @@ -0,0 +1,67 @@ +# $Id: PKGBUILD 106308 2014-02-27 10:52:25Z jelle $ +# Maintainer: +# Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve> +# Contributor: William Rea <sillywilly@gmail.com> +# Maintainer (Parabola): fauno <fauno@kiwwwi.com.ar> +# Contributor: borgo <nomail> +# Contributor (Parabola): André Silva <emulatorman@parabola.nu> + +pkgbase=python-reportlab-libre +pkgname=(python2-reportlab-libre python-reportlab-libre) +_origname=reportlab +pkgver=3.0 +pkgrel=1 +pkgdesc="A proven industry-strength PDF generating solution, without nonfree fonts support" +arch=('i686' 'x86_64') +url="http://www.reportlab.org/rl_toolkit.html" +depends=('freetype2') +checkdepends=('python' 'python2') +license=('custom') +source=(http://www.reportlab.com/ftp/reportlab-$pkgver.tar.gz + free-fonts.patch) +md5sums=('a4fd40abcfb604aa3bd907181133c071' + 'eb3ac47734efb05b939fb88026aff8ed') + +prepare() { + cd $srcdir + cp -rf ${_origname}-$pkgver "${_origname}2-$pkgver" + + _reportlab_source=("${_origname}-$pkgver" "${_origname}2-$pkgver") + + for x in ${_reportlab_source[@]}; do + cd $srcdir/$x + + # remove nonfree fonts support + patch -p1 -i $srcdir/free-fonts.patch + + # Parabola contains those fonts from the ttf-bitstream-vera package + rm -fv src/reportlab/fonts/{bitstream-vera-license.txt,Vera*} + done +} + +package_python2-reportlab-libre() { + conflicts+=('python2-reportlab' 'python-reportlab<=2.5-2') + replaces+=('python2-reportlab' 'python-reportlab<=2.5-2') + provides=("python2-reportlab=$pkgver") + depends=('python2') + cd "$srcdir/${_origname}2-$pkgver" + python2 setup.py install --root=$pkgdir --optimize=1 + install -D -m644 LICENSE.txt $pkgdir/usr/share/licenses/$_pkgname/license.txt +} + +package_python-reportlab-libre() { + conflicts+=('python-reportlab' 'python-reportlab-libre<=2.5-2') + replaces+=('python-reportlab' 'python-reportlab-libre<=2.5-2') + provides=("python-reportlab=$pkgver") + depends=('python3') + cd "$srcdir/${_origname}-$pkgver" + python3 setup.py install --root=$pkgdir --optimize=1 + install -D -m644 LICENSE.txt $pkgdir/usr/share/licenses/$_pkgname/license.txt +} + + +check() { + cd ${srcdir}/${_origname}-${pkgver} + python2 setup.py tests + python setup.py tests +} |