# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-samsung-jflte
pkgdesc="Samsung Galaxy S4"
pkgver=4
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="armv7"
options="!check !archcheck"
depends="
	postmarketos-base
	linux-samsung-jflte
	mkbootimg
	msm-fb-refresher
"
makedepends="devicepkg-dev"
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
source="deviceinfo kernel-cmdline.conf fb.modes"

build() {
	devicepkg_build $startdir $pkgname
}

package() {
	install -D -m644 "$srcdir"/fb.modes \
		"$pkgdir"/etc/fb.modes
	devicepkg_package $startdir $pkgname
}

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

sha512sums="
bcec052d6a70de8a1a21b0f6f08955f77f5200191ba0863d5ee6a1d3023414ff00eb3961fe82e3df9fffc330527f8b4069d3186a3f8a79cc3188057c9b317d12  deviceinfo
ac6545e7b812a53d4fffc8848801b0cfc90a83b2b281a65ee9d66b82ce76d31a5fdc24655c2d3dffbc32282a4313631ac9146821a15b2e1d955c5e8dcad2becc  kernel-cmdline.conf
515cd3be1816bea9a1859a37f6568e3e82a9f8f16cbbc71ba13d60723f98eafbda9046ebb1ee7f4ae23dd2b2b2b18506f64516ca45ff71af18e7c163f12248bd  fb.modes
"
