summaryrefslogtreecommitdiffstats
path: root/abs/core/python_modules/python-path/PKGBUILD
blob: d387ee7d5eedf8b66ba2b5613db32f7ff3bb2f36 (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
# $Id: PKGBUILD 171328 2016-04-18 11:00:47Z kkeen $
# Maintainer: Kyle Keen <keenerd@gmail.com>

pkgbase=python-path
pkgname=(python-path python2-path)
pkgver=10.4
pkgrel=1
pkgdesc="Aka path.py, implements path objects as first-class entities"
arch=('any')
url="https://pypi.python.org/pypi/path.py"
license=('MIT')
depends=('python' 'python-setuptools')
makedepends=('python-setuptools' 'python2-setuptools')
#source=("https://pypi.python.org/packages/source/p/path.py/path.py-$pkgver.tar.gz")
source=("https://files.pythonhosted.org/packages/source/p/path.py/path.py-$pkgver.tar.gz")
md5sums=('84ed5ec53c113554662194bb8cdfc04e')

# formerly a dependency of python-pickleshare
# now used by nothing so back to the AUR

prepare() {
  cd "$srcdir"
  cp -r path.py-$pkgver python2-path.py-$pkgver
}

package_python-path() {
  depends=('python' 'python-setuptools')
  cd "$srcdir/path.py-$pkgver"
  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
  install -d "$pkgdir/usr/share/licenses/$pkgname/"
  head -n 21 path.py > "$pkgdir/usr/share/licenses/$pkgname/license.txt"
}

package_python2-path() {
  depends=('python2' 'python2-setuptools')
  cd "$srcdir/python2-path.py-$pkgver"
  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
  install -d "$pkgdir/usr/share/licenses/$pkgname/"
  head -n 21 path.py > "$pkgdir/usr/share/licenses/$pkgname/license.txt"
}