summaryrefslogtreecommitdiffstats
path: root/testing/py-urwid/APKBUILD
diff options
context:
space:
mode:
authorMatt Smith <mcs@darkregion.net>2010-12-16 10:32:06 -0600
committerNatanael Copa <ncopa@alpinelinux.org>2010-12-16 19:58:54 +0000
commitb51ad0bb6585a76b1b726a88369ae0788aa28ce9 (patch)
tree171929a44ceb4d6412bb4e726297b36ed4bf265e /testing/py-urwid/APKBUILD
parentce99542a6396032c4239fcab963263f54d6dfb1a (diff)
downloadaports-b51ad0bb6585a76b1b726a88369ae0788aa28ce9.tar.bz2
aports-b51ad0bb6585a76b1b726a88369ae0788aa28ce9.tar.xz
testing/py-{templayer,urwid}: Improved APKBUILD
Diffstat (limited to 'testing/py-urwid/APKBUILD')
-rw-r--r--testing/py-urwid/APKBUILD33
1 files changed, 20 insertions, 13 deletions
diff --git a/testing/py-urwid/APKBUILD b/testing/py-urwid/APKBUILD
index 64ad1403f..4fe907447 100644
--- a/testing/py-urwid/APKBUILD
+++ b/testing/py-urwid/APKBUILD
@@ -1,21 +1,20 @@
# Contributor: Matt Smith <mcs@darkregion.net>
# Maintainer: Matt Smith <mcs@darkregion.net>
pkgname=py-urwid
-_name=urwid
+_pkgname=urwid
pkgver=0.9.9.1
-pkgrel=1
+pkgrel=2
pkgdesc="Urwid is a console user interface library for Python"
url="http://excess.org/urwid/"
arch="x86 x86_64"
license="LGPL"
depends="python"
-makedepends="python-dev py-templayer"
+makedepends="python-dev py-setuptools py-templayer"
install=
subpackages="$pkgname-doc"
-source="http://excess.org/$pkgname/$_name-$pkgver.tar.gz
- "
+source="http://excess.org/$_pkgname/$_pkgname-$pkgver.tar.gz"
-_builddir="$srcdir"/$_name-$pkgver
+_builddir="$srcdir"/$_pkgname-$pkgver
prepare() {
cd "$_builddir"
@@ -24,20 +23,28 @@ prepare() {
build() {
cd "$_builddir"
- python setup.py build
- return 0
+ python setup.py build || return 1
}
package() {
cd "$_builddir"
python setup.py install --root "$pkgdir"
+}
+
+doc() {
+ cd "$_builddir"
- # generate tutorial examples, and copy documentation
+ # generate tutorial examples, and copy documentation
python docgen_tutorial.py -s
- mkdir -p "$pkgdir"/usr/share/doc/$pkgname/tutorial_examples
- cp -a example*.py "$pkgdir"/usr/share/doc/$pkgname/tutorial_examples/
- install -Dm644 reference.html "$pkgdir"/usr/share/doc/$pkgname/reference.html
- install -Dm644 tutorial.html "$pkgdir"/usr/share/doc/$pkgname/tutorial.html
+ mkdir -p "$subpkgdir"/usr/share/doc/$pkgname/tutorial_examples
+ cp -a example*.py "$subpkgdir"/usr/share/doc/$pkgname/tutorial_examples/
+
+ for doc in CHANGELOG reference.html tutorial.html; do
+ install -Dm644 $doc "$subpkgdir"/usr/share/doc/$pkgname/$doc
+ done
+
+ # Fix subdir perms
+ find "$subpkgdir"/usr/share/doc/$pkgname/ -type d -exec chmod 755 '{}' \;
}
md5sums="4722cdf898f711dcae1121aa80920152 urwid-0.9.9.1.tar.gz"