# Template file for 'dropbear'
pkgname=dropbear
version=2025.89
revision=1
build_style=gnu-configure
configure_args="--enable-zlib --disable-bundled-libtom"
makedepends="zlib-devel libtommath-devel libtomcrypt-devel"
checkdepends="python3-pytest python3-parsing python3-psutil openssh"
short_desc="Small SSH server and client"
maintainer="Orphaned <orphan@voidlinux.org>"
license="MIT"
homepage="https://matt.ucc.asn.au/dropbear/dropbear.html"
changelog="https://matt.ucc.asn.au/dropbear/CHANGES"
distfiles="https://matt.ucc.asn.au/${pkgname}/releases/${pkgname}-${version}.tar.bz2"
checksum=0d1f7ca711cfc336dc8a85e672cab9cfd8223a02fe2da0a4a7aeb58c9e113634
make_dirs="/etc/dropbear 0755 root root"

if [ "$XBPS_TARGET_LIBC" = "glibc" ]; then
	makedepends+=" libxcrypt-devel"
fi

pre_check() {
	# These tests don't work from within xbps-src
	# and probably should not be run from there
	rm test/test_aslr.py
	rm test/test_channels.py
	# Required asyncssh not packaged for Void Linux
	rm test/test_concurrent.py
}

post_install() {
	vsv dropbear
	vlicense LICENSE
}
