name=newt
version=0.52.24
release=1
desc="Text-mode windowing library, used by nmtui"
url="https://pagure.io/newt"
license="LGPL-2.0-or-later"
depend="glibc slang"
makedepend=""
source="https://releases.pagure.org/newt/newt-0.52.24.tar.gz"
sha256="SKIP"

build() {
	cd "newt-0.52.24"
	[ -x ./configure ] || autoreconf -fi
	_opts="--prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=/usr/lib"
	_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
	case "$_help" in *--disable-dependency-tracking*) _opts="$_opts --disable-dependency-tracking" ;; esac
	./configure $_opts
	gmake -j"$JOBS"
}

package() {
	cd "newt-0.52.24"
	gmake DESTDIR="$pkgdir" install
}
