diff options
author | Carlo Landmeter <clandmeter@gmail.com> | 2017-10-23 11:28:48 +0200 |
---|---|---|
committer | Carlo Landmeter <clandmeter@gmail.com> | 2017-10-23 11:37:53 +0200 |
commit | edcafb0ba28f768d6cdd9df68a8aff35acc18968 (patch) | |
tree | c38182daededeb1b95fd7d9a737cb0bbcf918e0e /community/py-img2pdf/APKBUILD | |
parent | d3040d23415fc33d6ddef1174328a0c99caf0574 (diff) | |
download | aports-edcafb0ba28f768d6cdd9df68a8aff35acc18968.tar.bz2 aports-edcafb0ba28f768d6cdd9df68a8aff35acc18968.tar.xz |
testing/py-img2pdf: move to community
Diffstat (limited to 'community/py-img2pdf/APKBUILD')
-rw-r--r-- | community/py-img2pdf/APKBUILD | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/community/py-img2pdf/APKBUILD b/community/py-img2pdf/APKBUILD new file mode 100644 index 0000000000..ee406c9aaf --- /dev/null +++ b/community/py-img2pdf/APKBUILD @@ -0,0 +1,48 @@ +# Contributor: Carlo Landmeter <clandmeter@alpinelinux.org> +# Maintainer: Carlo Landmeter <clandmeter@alpinelinux.org> +pkgname=py-img2pdf +pkgver=0.2.4 +pkgrel=0 +pkgdesc="Convert images to PDF via direct JPEG inclusion" +url="https://gitlab.mister-muffin.de/josch/img2pdf" +arch="noarch" +license="LGPL" +depends="py-pillow" +makedepends="python2-dev python3-dev py-setuptools" +install="" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="https://pypi.python.org/packages/7e/a2/4f06081f674920be757d894b4bab874e6a3b5227e730cb7618430b366e69/img2pdf-$pkgver.tar.gz" +builddir="$srcdir/img2pdf-$pkgver" + +build() { + cd "$builddir" + python2 setup.py build + python3 setup.py build +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + replaces="$pkgname" + depends="${depends//py-/py2-}" + _py python2 +} + +_py3() { + depends="${depends//py-/py3-}" + _py python3 +} + +_py() { + local python="$1" + pkgdesc="$pkgdesc (for $python)" + depends="$depends $python" + install_if="$pkgname=$pkgver-r$pkgrel $python" + + cd "$builddir" + $python setup.py install --prefix=/usr --root="$subpkgdir" +} + +sha512sums="c2d99da7076411cf4acabe8929fc8af4005ef1f3e3d9edc953f2731b8d41159c9e4637a803765e1405c595daebfb3d519d4c7903003ce0118d8b0c6e88f11860 img2pdf-0.2.4.tar.gz" |