# Archived: Kernel does not build anymore
# Reference: <https://postmarketos.org/devicepkg>
maintainer=""
pkgname=device-mobvoi-skipjack
pkgdesc="Mobvoi Ticwatch C2"
pkgver=6
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="armv7"
options="!check !archcheck"
depends="
	linux-mobvoi-skipjack
	mkbootimg
	postmarketos-base
	mdss-fb-init-hack
"
subpackages="
	$pkgname-nonfree-firmware-modem:nonfree_firmware_modem
	$pkgname-nonfree-firmware-venus:nonfree_firmware_venus
	$pkgname-nonfree-firmware-wcnss:nonfree_firmware_wcnss
"
makedepends="devicepkg-dev"
source="deviceinfo kernel-cmdline.conf"

build() {
	devicepkg_build $startdir $pkgname
}

package() {
	devicepkg_package $startdir $pkgname
}

nonfree_firmware_modem() {
	pkgdesc="Modem firmware"
	depends="firmware-mobvoi-skipjack-modem"
	mkdir "$subpkgdir"
}

nonfree_firmware_venus() {
	pkgdesc="GPU firmware"
	depends="firmware-mobvoi-skipjack-venus"
	mkdir "$subpkgdir"
}

nonfree_firmware_wcnss() {
	pkgdesc="WiFi/Bluetooth firmware"
	depends="firmware-mobvoi-skipjack-wcnss"
	mkdir "$subpkgdir"
}

sha512sums="
a8c09bf0b22857c6e212737b2088b5b6a395f809a6271a3a42b7dd738626454639581008915d4f61acec77fa4f74b3b3822987e7ab507eb45d4f7fb51a2b9759  deviceinfo
d39374c1c0474ebf153045b2957bc76ee2f007f6454a96b80fb0ae97661f0723e5a6527e77c51a27daf3ffce537bc13b633c40d130e86ae6c66c0e06d92c46b3  kernel-cmdline.conf
"
