# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lxterminal
pkgver=0.3.0
pkgrel=2
pkgdesc="Desktop-independent VTE-based terminal emulator"
url="http://lxde.org/"
arch="all"
license="GPL-2.0-or-later"
depends=""
makedepends="vte-dev"
subpackages="$pkgname-doc $pkgname-lang"
source="https://downloads.sourceforge.net/lxde/$pkgname-$pkgver.tar.xz
	CVE-2016-10369.patch"
builddir="$srcdir"/$pkgname-$pkgver

# secfixes:
#   0.3.0-r1:
#     - CVE-2016-10369

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--localstatedir=/var
	make
}

check() {
	cd "$builddir"
	make -C src check
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

sha512sums="05eb6ef8904de9e34a4046ded67d3cece5a93a5b19d37d423f3bde67051a2f0a0e3195443669709a8b732d27246852353a2c9ba59026f9d71f8df6bb1152e37f  lxterminal-0.3.0.tar.xz
e9fc3d612a8a59e4fb7cd5c339759a7450c8829caa3645e9c859e603a450a173a9215670598d696dc8830de1c78b4a62959bfdb166962cd869ae5a9ec8bab33d  CVE-2016-10369.patch"
