# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-motorola-perry
pkgdesc="Motorola Moto E4"
pkgver=0.1
pkgrel=5
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
options="!check !archcheck"
depends="postmarketos-base linux-motorola-perry mkbootimg msm-fb-refresher mdss-fb-init-hack"
makedepends="devicepkg-dev"
source="deviceinfo initfs-hook.sh"

build() {
	devicepkg_build $startdir $pkgname
}

package() {
	devicepkg_package $startdir $pkgname
}

nonfree_firmware() {
	pkgdesc="Wifi firmware"
	depends="firmware-motorola-perry-wcnss wcnss-wlan"
	mkdir "$subpkgdir"
}


sha512sums="
9470782b0358a9a950cdce7aa406d54c2d0015d136db7b1c4fa8c08a9d8d57e749eeaa76d7d8a27a6973c2b86786ee2b452438d6d400b75636bb793ee0446526  deviceinfo
f33e8f7287659bcf738397f8f09bb51666820362dffd2c1dbb9afd28640ba22cc5e8f714ffbb1e0913d913fffdc95191cef38f933cfa77b15466ac633ab92d95  initfs-hook.sh
"
