# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-samsung-gtowifi
pkgdesc="Samsung Galaxy Tab A 8.0 2019"
pkgver=4
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="
	linux-samsung-gtowifi
	msm-fb-refresher
	mkbootimg
	postmarketos-base
"
makedepends="devicepkg-dev"
source="deviceinfo kernel-cmdline.conf"

subpackages="$pkgname-nonfree-firmware:nonfree_firmware"

build() {
	devicepkg_build $startdir $pkgname
}

package() {
	devicepkg_package $startdir $pkgname
}

nonfree_firmware() {
	pkgdesc="WiFi firmware"
	depends="firmware-samsung-gtowifi-wifi"
	mkdir "$subpkgdir"
}

sha512sums="
5952a5655f5836e0bde6c23fd5e0959356142507c3ff03b1b9ad33d4a3a4a1b1338417e60f5df6c075cdf16c8a15c1662aac2349f45d9e6b3753ff98c0f70841  deviceinfo
4f92b54a907e284c5077bbfeebbbd62f61aba441cc3cc36b063af263a1b39533f6de83744b98cca3d06d8b6a63b20d7c974b9413e7afdd9dbd860f9f1d2bcb59  kernel-cmdline.conf
"
