# Maintainer: Patrycja Rosa <alpine@ptrcnull.me>
pkgname=py3-cmake-build-extension
pkgver=0.6.1
pkgrel=0
pkgdesc="Setuptools extension to build and package CMake projects"
url="https://github.com/diegoferigo/cmake-build-extension"
arch="noarch"
license="MIT"
depends="python3"
makedepends="
	py3-gpep517
	py3-installer
	py3-setuptools_scm
	py3-wheel
	"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/diegoferigo/cmake-build-extension/archive/refs/tags/v$pkgver.tar.gz"
builddir="$srcdir/cmake-build-extension-$pkgver"
options="!check" # no tests

build() {
	export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
8e3e518f63ec86818f8e631ddad4a6d71136b4f4ed353c4d96cee951824a12ca7a065993e9a0deabf23b87a321f642b8362ae6699a3ee47d798dc0fd26241404  py3-cmake-build-extension-0.6.1.tar.gz
"
