summaryrefslogtreecommitdiff
path: root/user/py3-docutils
diff options
context:
space:
mode:
authorA. Wilcox <awilcox@wilcox-tech.com>2018-04-17 03:14:51 +0000
committerA. Wilcox <awilcox@wilcox-tech.com>2018-04-17 03:14:51 +0000
commit58df66140118743fa73b00a0861268771454a52d (patch)
tree8eab53269041756630a60e5b5eabc5a852eb3de8 /user/py3-docutils
parent5217ef782dbc8fed1658ce8eaa0020067ef164ce (diff)
parenteed15ce883433b15cd0254898275ea7dceea0bad (diff)
downloadpackages-58df66140118743fa73b00a0861268771454a52d.tar.gz
packages-58df66140118743fa73b00a0861268771454a52d.tar.bz2
packages-58df66140118743fa73b00a0861268771454a52d.tar.xz
packages-58df66140118743fa73b00a0861268771454a52d.zip
Merge branch 'meta/docutils' into 'master'
docutils and friends ``` Includes: * user/py3-docutils * user/py3-roman * user/py3-pillow * user/py3-olefile ``` See merge request !17
Diffstat (limited to 'user/py3-docutils')
-rw-r--r--user/py3-docutils/APKBUILD51
1 files changed, 51 insertions, 0 deletions
diff --git a/user/py3-docutils/APKBUILD b/user/py3-docutils/APKBUILD
new file mode 100644
index 000000000..e227ada63
--- /dev/null
+++ b/user/py3-docutils/APKBUILD
@@ -0,0 +1,51 @@
+# Contributor: Max Rees <maxcrees@me.com>
+# Maintainer: Max Rees <maxcrees@me.com>
+pkgname=py3-docutils
+_pkgname=docutils
+pkgver=0.14
+pkgrel=0
+pkgdesc="Documentation utilities for Python"
+url="https://pypi.python.org/pypi/docutils"
+arch="noarch"
+license="Custom"
+depends="python3 py3-pillow py3-roman"
+makedepends="python3-dev py3-setuptools"
+subpackages="$pkgname-doc"
+source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
+builddir="$srcdir/$_pkgname-$pkgver"
+
+build() {
+ cd "$builddir"
+ python3 setup.py build
+}
+
+check() {
+ cd "$builddir/test3"
+ python3 alltests.py
+}
+
+package() {
+ cd "$builddir"
+ python3 setup.py install --prefix=/usr --root="$pkgdir"
+
+ # Remove .py extension from executable files.
+ local path; for path in "$pkgdir"/usr/bin/*.py; do
+ mv "$path" "${path%.py}"
+ done
+}
+
+doc() {
+ cd "$builddir"
+
+ local docdir="$subpkgdir/usr/share/doc/$pkgname"
+ mkdir -p "$docdir"
+ cp -R docs/* "$docdir"
+ cp *.txt "$docdir"
+
+ local licdir="$subpkgdir/usr/share/licenses/$pkgname"
+ mkdir -p "$licdir"
+ rm -f licenses/docutils.conf
+ cp licenses/* "$licdir"
+}
+
+sha512sums="1ed72c2ef7d2ca38d1c6f3154b7986ea46f599d9bd826405a5257fdd7740c8626957d6298aa95fb0edea8a24515de22f1ad9b2ecbd59341a1ab7a2bab30f500c py3-docutils-0.14.tar.gz"