# Contributor: Fabian Affolter # Maintainer: Fabian Affolter setvar pkgname = 'py-mock' setvar _pkgname = 'mock' setvar pkgver = '2.0.0' setvar pkgrel = '3' setvar pkgdesc = ""A Python Mocking and Patching Library for Testing"" setvar url = ""https://github.com/testing-cabal/mock"" setvar arch = ""noarch"" setvar license = ""BSD"" setvar depends = ""py-pbr py-six"" setvar makedepends = ""python2-dev python3-dev py-setuptools"" setvar subpackages = ""py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"" setvar source = ""$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"" setvar builddir = ""$srcdir/$_pkgname-$pkgver"" proc build { cd $builddir python2 setup.py build || return 1 python3 setup.py build || return 1 } proc package { mkdir -p $pkgdir } proc _py2 { setvar replaces = "$pkgname" setvar depends = ""${depends//py-/py2-} py2-funcsigs"" _py python2 } proc _py3 { setvar depends = "${depends//py-/py3-}" _py python3 } proc _py { local python="$1" setvar pkgdesc = ""$pkgdesc (for $python)"" setvar depends = ""$depends $python"" setvar install_if = ""$pkgname=$pkgver-r$pkgrel $python"" cd $builddir $python setup.py install --prefix=/usr --root="$subpkgdir" } setvar md5sums = ""0febfafd14330c9dcaa40de2d82d40ad py-mock-2.0.0.tar.gz"" setvar sha256sums = ""b158b6df76edd239b8208d481dc46b6afd45a846b7812ff0ce58971cf5bc8bba py-mock-2.0.0.tar.gz"" setvar sha512sums = ""a08007651b749d2843b94f5045d74c122958888290aea21930455538a854e6b04c07115e21d82edde996154bf597d7a8784a2f4213cbabc49a98dec22dd92238 py-mock-2.0.0.tar.gz""