# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=xf86-input-libinput
pkgver=0.27.0
pkgrel=0
pkgdesc="X.Org input driver based on libinput"
url="http://xorg.freedesktop.org"
arch="all"
license="MIT"
depends=""
depends_dev="libinput-dev xorg-server-dev"
makedepends="$depends_dev resourceproto scrnsaverproto eudev-dev"
subpackages="$pkgname-dev $pkgname-doc"
source="https://www.x.org/releases/individual/driver/$pkgname-$pkgver.tar.bz2
	0001-Fix-left-handed-property-not-set-on-all-pointers.patch"
builddir="$srcdir/$pkgname-$pkgver"

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

check() {
	cd "$builddir"
	make check
}

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

sha512sums="716a9b43438acd6b7c6a834a08ecec244fecdc31e77241998414bf1748781026cd6c6e85947155c44400e0192769a714dfbfa0ed42ba3677347cd89ac1081743  xf86-input-libinput-0.27.0.tar.bz2
4eda5ac30bcba9796e96c78e1b1f5da78b56c4edd72627e9518b492b586adbf190382b3cc0710ab9e9497f5ed1e97f78c1674436bb12e23b33a0f92d6058a4c5  0001-Fix-left-handed-property-not-set-on-all-pointers.patch"
