aboutsummaryrefslogblamecommitdiffstats
path: root/community/py-ws4py/APKBUILD
blob: c6cf511492e5443e34794207e5796aacd581ff49 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11



                                                           
            
        




                                                                                
                                     

                                                   
                                                                                                          



                                    
                                          


                                          
 
           
                          




                                    

                                                      

                                                                  



                   
                           





                   
                                                                                                                                                                 
# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=py-ws4py
_pkgname=ws4py
pkgver=0.5.1
pkgrel=0
pkgdesc="WebSocket client and server library for Python 2 and 3 as well as PyPy"
url="https://github.com/Lawouach/WebSocket-for-Python"
arch="noarch"
license="BSD"
depends=""
makedepends="python2-dev python3-dev"
install=""
subpackages="py3-$_pkgname:_py3 py2-$_pkgname:_py2"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"

build() {
	cd "$builddir"
	python2 setup.py build || return 1
	python3 setup.py build || return 1
}


package() {
	mkdir -p "$pkgdir"
}

_py() {
	local python=$1
	pkgdesc="$pkgdesc - $python"
	install_if="$pkgname=$pkgver-r$pkgrel $python"

	cd "$builddir"
	$python setup.py install --prefix=/usr --root="$subpkgdir"
}

_py2() {
	_py python2
	replaces="$pkgname"
}

_py3() {
	_py python3
}

sha512sums="e3202d7bc547a5447eaeeeabe2ff18bd884c89c02cf54e27d88ca9cd14bcd9f080f7ff7e02d36538200c096df0442809c171c99e37b16ff818866c45b40eeef9  ws4py-0.5.1.tar.gz"