pmaports/device/testing/firmware-xiaomi-surya/APKBUILD
Danila Tikhonov 6e3372541b
firmware-xiaomi-surya: update firmware (MR 4547)
Signed-off-by: Danila Tikhonov <danila@jiaxyga.com>
2024-02-13 12:57:05 +01:00

81 lines
2 KiB
Text

pkgname=firmware-xiaomi-surya
pkgver=1.1
pkgrel=0
pkgdesc="Firmware for Xiaomi POCO X3 NFC"
subpackages="
$pkgname-adsp
$pkgname-cdsp
$pkgname-ipa
$pkgname-modem
$pkgname-touchscreen
$pkgname-wlan
"
url="https://github.com/sm7150-mainline/firmware-xiaomi-surya"
arch="aarch64"
license="proprietary"
options="!check !strip !archcheck !tracedeps pmb:cross-native"
_commit="3d76e775502966ac4aa9d6e563a71d7442152f1b"
source="$pkgname-$_commit.tar.gz::$url/archive/$_commit/$pkgname-$_commit.tar.gz"
builddir="$srcdir/$pkgname-$_commit"
package() {
# parent package is empty
mkdir -p "$pkgdir"
}
adsp() {
pkgdesc="Xiaomi POCO X3 NFC adsp firmware"
install -Dm644 "$builddir"/adsp* -t \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
}
cdsp() {
pkgdesc="Xiaomi POCO X3 NFC cdsp firmware"
install -Dm644 "$builddir"/cdsp* -t \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
}
ipa() {
pkgdesc="Xiaomi POCO X3 NFC ipa firmware"
install -Dm644 "$builddir"/ipa_fws.* -t \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
}
modem() {
pkgdesc="Xiaomi POCO X3 NFC modem firmware"
# cp because of the modem_pr directory
mkdir -p "$subpkgdir/lib/firmware/qcom/sm7150/surya"
cp -r "$builddir"/modem* \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
find "$subpkgdir/lib/firmware/qcom/sm7150/surya" \
-type f -exec chmod 0644 {} \;
}
touchscreen() {
pkgdesc="Xiaomi POCO X3 NFC touchscreen firmware"
install -Dm644 "$builddir"/novatek_ts_*_fw.bin -t \
"$subpkgdir/lib/firmware"
}
venus() {
pkgdesc="Xiaomi POCO X3 NFC venus firmware"
install -Dm644 "$builddir"/venus.mbn -t \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
}
wlan() {
pkgdesc="Xiaomi POCO X3 NFC wlan firmware"
install -Dm644 "$builddir"/wlanmdsp.mbn -t \
"$subpkgdir/lib/firmware/qcom/sm7150/surya"
}
sha512sums="
769bcbabc12919f2fd8b9f6c4f23a236ba1835eb4cedef9072652321ee145995eff4f8b7b34a7875de9d26b9cdd9e7ccbcc1063cbc8eeb2b3ca3fbe3d0affad5 firmware-xiaomi-surya-3d76e775502966ac4aa9d6e563a71d7442152f1b.tar.gz
"