summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7aedf549442a85dd4ffdf0f768eaeeccce9dfe2f (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
# Maintainer: otaj
#
# Thanks to Jeremy "Ichimonji10" Audet <ichimonji10 at gmail dot com> for
# his PKGBUILD that served as a base for this one

pkgname=python-foolbox-git
_name=foolbox
pkgdesc="Toolbox to create adversarial examples that fool neural networks in PyTorch, TensorFlow, Keras,"
pkgver=3.1.1.r0.gef30f7f
pkgrel=1
arch=(any)
url='https://github.com/bethgelab/foolbox'
license=(MIT)
provides=('python-foolbox')
conflicts=('python-foolbox')
depends=('python-numpy' 'python-scipy' 'python-gitpython' 'python-requests' 'python-eagerpy')
makedepends=(
  'python-setuptools' 'git'
)
options=(!emptydirs)
source=("git+$url.git")
sha256sums=('SKIP')

pkgver() {
  cd $_name
  git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

package() {
  cd "${srcdir}/$_name"
  python setup.py install --root="${pkgdir}/" --optimize=1
  install -Dm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}