blob: 65dfbb9c6878493f6a3d5f14e793a024247a5104 (
plain)
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
|
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=py-imagesize
_pkgname=imagesize_py
pkgver=0.7.1
pkgrel=2
pkgdesc="Getting image size from png/jpeg/jpeg2000/gif file"
url="https://github.com/shibukawa/imagesize_py"
arch="noarch"
license="MIT"
depends=""
makedepends="python2-dev python3-dev py-setuptools"
subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
source="$pkgname-$pkgver.tar.gz::https://github.com/shibukawa/$_pkgname/archive/$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"
build() {
cd "$builddir"
python2 setup.py build || return 1
python3 setup.py build || return 1
}
package() {
mkdir -p "$pkgdir"
}
_py2() {
replaces="$pkgname"
_py python2
}
_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"
}
md5sums="1ddd41c09cf289a8897fda3cfe8f72e2 py-imagesize-0.7.1.tar.gz"
sha256sums="781367e05a2aba5b66c76e46394cf627bfdd85dba94e066c49df7d57897c67c3 py-imagesize-0.7.1.tar.gz"
sha512sums="05f6db46d871eef6771a8b1e797bb6c9c33af3bab1efd86d2abf365e91575823cfad905162656606f552a0fab7d59a3596a2210d4246e0148ea605ffc01eb733 py-imagesize-0.7.1.tar.gz"
|