summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 0c55320784ea8872fa74d9c51aab56418c884ab0 (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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# Maintainer: Matteo Piccinini (loacker) <matteo.piccinini@gmail.com>
# Contributor: BigfootACA <bigfoot@classfun.cn>

pkgname=python-oslo-middleware
pkgver=6.6.0
pkgrel=1
pkgdesc="OpenStack middleware library"
arch=(any)
url="https://opendev.org/openstack/oslo.middleware"
license=('Apache-2.0')
depends=(
    'python'
    'python-pbr'
    'python-jinja'
    'python-oslo-config'
    'python-oslo-context'
    'python-oslo-i18n'
    'python-oslo-utils'
    'python-stevedore'
    'python-webob'
    'python-debtcollector'
    'python-statsd'
    'python-bcrypt'
    'python-greenlet'
    'python-oslotest'
    'python-testtools'
    'python-fixtures'
    'python-oslo-serialization'
    'python-requests'
    'python-typing_extensions'
)
makedepends=(
    'python-build'
    'python-installer'
    'python-sphinx'
    'python-setuptools'
    'python-wheel'
    'git'
)
checkdepends=(
    'python-fixtures'
    'python-oslotest'
    'python-testtools'
    'python-coverage'
    'python-oslo-serialization'
    'python-stestr'
)
source=("$pkgname-$pkgver::git+$url.git#tag=$pkgver")
b2sums=('c71378cb249412c7a7123c23cb36a422ca214827ae2afbc27b0eb00795cbd471c3ee246ef30f1fe7f2730157953c517be6c8884776a9ec79cf3bd7fd641cbf48')

build(){
    cd "$pkgname-$pkgver" || exit
    PBR_VERSION=$pkgver python -m build --wheel --no-isolation
}

check(){
    cd "$pkgname-$pkgver" || exit
    stestr run
}

package(){
    cd "$pkgname-$pkgver" || exit
    python -m installer --destdir="$pkgdir" dist/*.whl
    install -Dm644 README.rst -t "$pkgdir/usr/share/$pkgname/"
    install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
}