description="Python library useful for writing tests for software which talks to D-Bus services."
url="https://github.com/martinpitt/python-dbusmock"

license="GPL3"

packager="spiky <spiky@nutyx.org>"
contributors="Tnut"

run=(python-dbus python-gobject)
makedepends=(python-setuptools)

name=python-dbusmock
_name="python-dbusmock"
alias=(${_name})

version=0.32.1

source=(https://github.com/martinpitt/$name/releases/download/$version/dist.${name}-$version.tar.gz)

build() {

 cd ${_name}-$version

  pip3 wheel -w dist \
    --no-build-isolation \
    --no-deps $PWD
  pip3 install --no-index \
    --find-links dist \
    --no-cache-dir    \
    --no-user         \
    --root=$PKG       \
    ${_name}

 find $PKG -type d -name vendor -o -name tests |xargs rm -rf 

install -Dm644 COPYING $PKG/usr/share/licenses/$name/COPYING

}
