# Template file for 'cbindgen'
pkgname=cbindgen
version=0.29.4
revision=1
build_style=cargo
checkdepends="cmake-bootstrap python3 python3-Cython"
short_desc="Tool to generate C bindings for Rust code"
maintainer="Duncaen <duncaen@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/mozilla/cbindgen"
changelog="https://raw.githubusercontent.com/mozilla/cbindgen/refs/heads/main/CHANGES"
distfiles="https://github.com/mozilla/cbindgen/archive/refs/tags/v${version}.tar.gz"
checksum=9b5757e915cf8be523d3aca282b9b5651bafa112e14bf1ba488562ba282807d6

pre_check() {
	# cmake required, use cmake-bootstrap
	export PATH="/usr/libexec/xbps-src/bin:$PATH"
	# XXX: need for error: the option `Z` is only accepted on the nightly compiler
	export RUSTC_BOOTSTRAP=1
}
