aboutsummaryrefslogtreecommitdiffstats
path: root/main/py3-sphinx/APKBUILD
blob: bc54229fdd65dc6501892ff36d6b36af48a74e5a (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
# Contributor: Carlo Landmeter <clandmeter@alpinelinux.org>
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py3-sphinx
pkgver=3.2.1
pkgrel=0
pkgdesc="Python	Documentation Generator"
# checkdepends require 'imagemagick' and 'py3-html5lib' which
# are in community/, 'imagemagick' itself also needs 'librsvg'
# and 'libheif', which bring in 'rust', 'x265' and others, this
# is too much of a burden to put on main/
options="!check"
url="http://sphinx.pocoo.org/"
arch="noarch"
license="BSD-2-Clause"
depends="
	py3-babel
	py3-docutils
	py3-imagesize
	py3-jinja2
	py3-pygments
	py3-requests
	py3-setuptools
	py3-snowballstemmer
	py3-alabaster
	py3-sphinxcontrib-applehelp
	py3-sphinxcontrib-devhelp
	py3-sphinxcontrib-htmlhelp
	py3-sphinxcontrib-jsmath
	py3-sphinxcontrib-serializinghtml
	py3-sphinxcontrib-qthelp
	"
# imagemagick is for tests/test_ext_imgconverter.py::test_ext_imgconverter
# which calls the 'convert' binary
checkdepends="py3-pytest py3-funcsigs py3-pluggy imagemagick py3-html5lib"
source="$pkgname-$pkgver.tar.gz::https://github.com/sphinx-doc/sphinx/archive/v$pkgver.tar.gz"
builddir="$srcdir/sphinx-$pkgver"

build() {
	python3 setup.py build
}

check() {
	make PYTHON=python3 test
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"

	# TODO: The binaries with the -3 postfix should be
	# considered deprecated and removed in a future release.
	local path; for path in "$pkgdir"/usr/bin/*; do
		mv "$path" "$path"-3
	done

	cd "$pkgdir"/usr/bin
	local name; for name in *-3; do
		ln -s -- $name "$pkgdir"/usr/bin/${name%-3}
	done
}

sha512sums="e45fc61b3a2812a34b3c876fda7292daac00fb4a985cf4ce243093b4582572fe0a56fad08b518567abfda9fc0f17e6d09f1325f39e219c8ea14ec80998ef0637  py3-sphinx-3.2.1.tar.gz"