# Contributor: Fabian Affolter # Maintainer: Fabian Affolter pkgname=awake pkgver=1.0 pkgrel=1 pkgdesc="A python command and library to 'wake on lan' a remote host" url="https://github.com/cyraxjoe/awake" arch="noarch" license="GPL3" depends="py3-awake" makedepends="python3-dev" subpackages="py3-$pkgname:py3 $pkgname-doc" source="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 || return 1 } package() { cd "$builddir" python3 setup.py install --prefix=/usr --root="$pkgdir" } py3() { pkgdesc="Python library for $pkgname" depends="python3" mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/ } doc() { # Doc files _docs="LICENSE README" for _doc in $_docs; do install -Dm644 "$srcdir"/$pkgname-$pkgver/$_doc \ "$subpkgdir"/usr/share/doc/$pkgname/$_doc || return 1 done } md5sums="57b7a2e616e37fc29b4011a2e1cc60b2 awake-1.0.tar.gz" sha256sums="a4be9058c08ed702b700c9e10e270a7355ba1563f22ad6b2dbd334c6bb5a1730 awake-1.0.tar.gz" sha512sums="3b9a69d39c48ef139b6ea125f6f6de36fc861430b6ccd6341bdc82369947745f879e2776fbfda6e3dfae3c0384ecab3fc35f724a4abe760b21ec91ef27562f4d awake-1.0.tar.gz"