summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b4380b1dfcdf0cac17b12d56b261066f57701474 (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
# Maintainer: Jeffrey Zhang <zhang.lei.fly@gmail.com>

_pkgname=ara
pkgname=python-${_pkgname}
pkgver=1.6.1
pkgrel=1
pkgdesc="ARA Records Ansible and makes it easier to understand and troubleshoot."
arch=("any")
url="https://github.com/ansible-community/ara"
license=('GPL-3.0')
depends=("python-cliff"
         "python-pbr"
         "python-requests")
provides=("ara")
optdepends=(
    "python-django"
    "python-django-rest-framework"
    "python-django-cors-headers"
    "python-django-filter"
    # FIXME: still require following packages
    # "django-health-check"
    # "python-dynaconf"
    "python-tzlocal"
    "python-whitenoise"
    "python-pygments"
    "python-psycopg2"
    )
makedepends=('python-setuptools')
source=("https://files.pythonhosted.org/packages/d8/21/64905ea535a94e72508b0a3a7d0fae28ac420f1db63729d660dd29c22a4d/ara-${pkgver}.tar.gz")
sha256sums=('90812ee38308b87db357d34f9fd9dd422c87edb3cdc0248a83f65b1bf0691b6d')

build() {
    cd ${_pkgname}-${pkgver}
    python setup.py build
}

package() {
    local site_packages=$(python -c "import site; print(site.getsitepackages()[0])")

    cd ${_pkgname}-${pkgver}
    python setup.py install --root="$pkgdir" --optimize=1 --skip-build
    # rm -rf "${pkgdir}${site_packages}/test"
    install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}