summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7f6a1f037bd8cb999dd2ad24675cdb2bec36cc73 (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
# Maintainer: buckket <buckket@cock.li>

pkgname=("python-spotify" "python2-spotify")
_pkgname=pyspotify
pkgver=2.0.5
pkgrel=4
pkgdesc="A Python wrapper for libspotify."
arch=("i686" "x86_64")
license=("APACHE")
url="http://pyspotify.mopidy.com/"
makedepends=("python-setuptools" "python2-setuptools")
conflicts=("python2-pyspotify" "pyspotify")
source=("https://pypi.python.org/packages/source/p/${_pkgname}/${_pkgname}-${pkgver}.tar.gz")
sha256sums=('fbd41c58d62232b0cabb7a9e38d45f36ac221699c006899bdb6be74c04602678')

prepare() {
  cp -r ${_pkgname}-${pkgver} "python-spotify-${pkgver}"
  cp -r ${_pkgname}-${pkgver} "python2-spotify-${pkgver}"
}

build_python-spotify() {
  cd ${pkgname}-${pkgver}
  python setup.py build
}

build_python2-spotify() {
  cd ${pkgname}-${pkgver}
  python2 setup.py build
}

package_python-spotify() {
  depends=("libspotify" "python-cffi")
  cd ${pkgname}-${pkgver}
  python setup.py install --root="${pkgdir}" --optimize=1
}

package_python2-spotify() {
  depends=("libspotify" "python2-cffi")
  cd ${pkgname}-${pkgver}
  python2 setup.py install --root="${pkgdir}" --optimize=1
}