name=vim
version=9.2.0100
release=2
replaces="toybox"
desc="Vi improved"
url="https://www.vim.org/"
license="Vim"
depend="glibc netbsd-curses libxcrypt"
makedepend=""
source="https://github.com/vim/vim/archive/refs/tags/v9.2.0100.tar.gz"
sha256="SKIP"

build() {
	cd "vim-9.2.0100"
	_opts="--prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=/usr/lib \
		--enable-gui=no --without-x --without-wayland \
		--disable-canberra --disable-libsodium --disable-acl"
	_help=$(./configure --help 2>/dev/null)
	case "$_help" in *--disable-static*)  _opts="$_opts --disable-static" ;; esac
	case "$_help" in *--disable-nls*)     _opts="$_opts --disable-nls" ;; esac
	./configure $_opts
	make -j"$JOBS"
}

package() {
	cd "vim-9.2.0100"
	make DESTDIR="$pkgdir" install
}
