2021-11-26 16:28:51 +00:00
|
|
|
# Maintainer: Alexander Martinz <amartinz@shiftphones.com>
|
|
|
|
|
|
|
|
pkgname=firmware-shift-sdm845
|
2024-04-14 11:38:42 +00:00
|
|
|
pkgver=20240517
|
|
|
|
pkgrel=0
|
2021-11-26 16:28:51 +00:00
|
|
|
pkgdesc="Firmware for SHIFT sdm845 devices"
|
|
|
|
url="https://gitlab.com/sdm845-mainline/firmware-shift-sdm845"
|
|
|
|
arch="aarch64"
|
|
|
|
depends="
|
|
|
|
linux-firmware-ath10k
|
|
|
|
linux-firmware-qcom
|
|
|
|
"
|
|
|
|
license="proprietary"
|
2023-05-01 13:18:24 +00:00
|
|
|
# Textrels appear in DSP libraries which we cannot avoid
|
|
|
|
options="!check !strip !archcheck !tracedeps textrels pmb:cross-native"
|
2021-11-26 16:28:51 +00:00
|
|
|
|
2024-04-14 11:38:42 +00:00
|
|
|
_version="7065892b9e6302e16803872231b30d588ef4b0da"
|
2021-11-26 16:28:51 +00:00
|
|
|
|
|
|
|
source="$pkgname.tar.gz::$url/-/archive/$_version/$pkgname-$_version.tar.gz
|
|
|
|
firmware.files
|
2023-05-01 13:18:24 +00:00
|
|
|
sensors.files
|
2023-10-02 11:59:07 +00:00
|
|
|
30-shift-sdm845-firmware-ci.files
|
2024-04-14 11:38:42 +00:00
|
|
|
"
|
2021-11-26 16:28:51 +00:00
|
|
|
subpackages="
|
2023-10-02 11:59:07 +00:00
|
|
|
$pkgname-pmtest
|
2023-05-01 13:18:24 +00:00
|
|
|
$pkgname-sensors:firmware_sensors
|
2023-10-02 11:59:07 +00:00
|
|
|
"
|
2021-11-26 16:28:51 +00:00
|
|
|
|
|
|
|
package() {
|
|
|
|
while IFS="" read -r _i || [ -n "$_i" ]; do
|
|
|
|
[ ! -d $(dirname $_i) ] && mkdir -p $(dirname $_i)
|
2024-04-14 11:38:42 +00:00
|
|
|
install -Dm644 "$srcdir/$pkgname-$_version/$_i" "$pkgdir/$_i"
|
2021-11-26 16:28:51 +00:00
|
|
|
done < "$srcdir/firmware.files"
|
2023-08-17 09:18:37 +00:00
|
|
|
|
2024-04-14 11:38:42 +00:00
|
|
|
# Install symlinks for using upstream firmware
|
|
|
|
ln -s ../mba.mbn "$pkgdir"/lib/firmware/qcom/sdm845/axolotl/mba.mbn
|
|
|
|
ln -s ../../../ath10k/WCN3990/hw1.0/wlanmdsp.mbn "$pkgdir"/lib/firmware/qcom/sdm845/axolotl/wlanmdsp.mbn
|
2021-11-26 16:28:51 +00:00
|
|
|
}
|
|
|
|
|
2023-10-02 11:59:07 +00:00
|
|
|
pmtest() {
|
|
|
|
install_if="$pkgname=$pkgver-r$pkgrel postmarketos-mkinitfs-hook-ci"
|
|
|
|
|
|
|
|
install -Dm644 "$srcdir/30-shift-sdm845-firmware-ci.files" \
|
|
|
|
"$subpkgdir/usr/share/mkinitfs/files/30-shift-sdm845-firmware-ci.files"
|
|
|
|
}
|
|
|
|
|
2023-05-01 13:18:24 +00:00
|
|
|
firmware_sensors() {
|
|
|
|
pkgdesc="Firmware files of the sensor registry"
|
|
|
|
depends="$pkgname"
|
|
|
|
install_if="$pkgname-nonfree-firmware"
|
|
|
|
mkdir "$subpkgdir"
|
|
|
|
|
|
|
|
cd "$srcdir/$pkgname-$_version/"
|
|
|
|
while IFS="" read -r _i || [ -n "$_i" ]; do
|
|
|
|
[ ! -d $(dirname $_i) ] && mkdir -p $(dirname $_i)
|
|
|
|
echo $_i
|
|
|
|
install -Dm644 $_i "$pkgdir/$_i"
|
|
|
|
done < "$srcdir/sensors.files"
|
|
|
|
}
|
|
|
|
|
2021-11-26 16:28:51 +00:00
|
|
|
sha512sums="
|
2024-04-14 11:38:42 +00:00
|
|
|
19d0f5debd851f6c5f2b460b72ee714265d48e5e12051cbde321dc97ebe235897ba377e67fc34cd6234611b12bdf20da6696f60621b855d9a9b912260d0f440e firmware-shift-sdm845.tar.gz
|
|
|
|
842f4e182da48cff45a41dcdb0cfe0a8fce1e1883a95177fe176a59797ade722a5b444eae1e572c7b2a9d5c8c0e4511ca2d561a3fc22cf79e853d3ccc9f676b6 firmware.files
|
|
|
|
ef495c515cb16c7d6aebaf1c6a23883768228282ea39118b6a19bed12a41e4777bf67b2436fc553b204a1a02672df54b9bc33f2c3946b7e688e78cd87c51448e sensors.files
|
2023-10-02 11:59:07 +00:00
|
|
|
97756b554cc0f91a69f511496663a012287517ec5853167246fe59c4deeb1cbf1eb352ec267bd0ad897e3f30547d2ad2818e70b597d9dfec26db45efca85b3f2 30-shift-sdm845-firmware-ci.files
|
2021-11-26 16:28:51 +00:00
|
|
|
"
|