description="Python bindings for YAML, using fast libYAML library"
url="http://pyyaml.org/wiki/PyYAML"

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

makedepends=(yaml cython)

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

version=6.0.2

PKGMK_KEEP_SOURCES="no"
source=(731.patch
        https://files.pythonhosted.org/packages/source/P/PyYAML/pyyaml-$version.tar.gz)

#prepare() {
# cd PyYAML-$version
# patch -Np1 -i $SRC/731.patch
#}

build() {
  cd pyyaml-$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
}
