pkgname=device-samsung-i9100
pkgver=1
pkgrel=20
pkgdesc="Samsung Galaxy SII"
url="https://github.com/postmarketOS"
arch="noarch"
license="MIT"
depends="postmarketos-base linux-samsung-i9100 libsamsung-ipc mesa-dri-swrast"
makedepends=""
install="$pkgname.post-install"
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
source="
	deviceinfo
	90-android-touch-dev.rules
	$install
"
options="!check"

package() {
	install -D -m644 "$srcdir/deviceinfo" \
		"$pkgdir/etc/deviceinfo"
	install -D -m644 "$srcdir"/90-android-touch-dev.rules \
		"$pkgdir"/etc/udev/rules.d/90-android-touch-dev.rules
}

nonfree_firmware() {
	pkgdesc="Wifi firmware"
	depends="firmware-samsung-i9100"
	mkdir "$subpkgdir"
}

sha512sums="7db735478615e9c493ac4a1b0bade3c12fefb7595cb633deef4de21bab690dcf45e963e610f318137db02caf1861c3ca56bcefc47073b7f62aef58224f8005f1  deviceinfo
089635daddd88eec35451bfe98dc3713035e3623c896dd21305b990ecf422e8fbb54e010cf347919bbb3a7385f639ab119280477fe0783df3228168d97d96fc6  90-android-touch-dev.rules
03da52725e676bc7db371cbf4b60bff8689eca469dae96a02ca7d6c194ed9f8c4ec9d19d1ac9212eeba0b73384fd213e86f2b93da94f37e5abe4cc3339281205  device-samsung-i9100.post-install"
