# Template file for 'netbsd-curses'
pkgname=netbsd-curses
version=0.3.2
revision=3
build_style=gnu-makefile
short_desc="Drop in replacement ported from netbsd. Smaller than ncurses"
maintainer="Tuxliban Torvalds <tenshalito@gmail.com>"
license="BSD-3-Clause"
homepage="https://github.com/sabotage-linux/netbsd-curses"
distfiles="${homepage}/archive/refs/tags/v${version}.tar.gz"
checksum=9d3ebd651e5f70b87b1327b01cbd7e0c01a0f036b4c1371f653b7704b11daf23

do_build() {
	make CC=$CC CFLAGS+=" -fPIC"
}

post_install() {
	cp COPYING LICENSE
	vlicense LICENSE
	cd ${DESTDIR}/usr/bin
	ln -sf tic captoinfo
	ln -sf tic infotocap
}

netbsd-curses-devel_package() {
	short_desc+=" -- development files"
	pkg_install() {
		vmove usr/include
		vmove usr/lib/pkgconfig
		vmove usr/lib/*.a
		vmove usr/lib/*.so
		vmove usr/share/man/man3
	}
}
