mirror of
https://github.com/archlinux-jerry/pkgbuilds
synced 2024-11-29 09:20:41 +08:00
add wifi binary, change install dir
This commit is contained in:
parent
1dfb9c18c6
commit
c9600496a3
2 changed files with 8 additions and 7 deletions
|
@ -1,10 +1,9 @@
|
||||||
# Maintainer: Megumifox <i@megumifox.com>
|
|
||||||
|
|
||||||
buildarch=28
|
buildarch=28
|
||||||
|
|
||||||
pkgname=firmware-phicomm-n1
|
pkgname=firmware-phicomm-n1
|
||||||
pkgver=7
|
pkgver=7
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
pkgdesc="Additional firmware for Phicomm N1"
|
pkgdesc="Additional firmware for Phicomm N1"
|
||||||
arch=('any')
|
arch=('any')
|
||||||
conflicts=('firmware-raspberrypi')
|
conflicts=('firmware-raspberrypi')
|
||||||
|
@ -17,13 +16,15 @@ _commitid_bt=96eefffcccc725425fd83be5e0704a5c32b79e54
|
||||||
options=('!strip')
|
options=('!strip')
|
||||||
source=("https://raw.githubusercontent.com/RPi-Distro/firmware-nonfree/$_commitid_wl/brcm/brcmfmac43455-sdio.clm_blob"
|
source=("https://raw.githubusercontent.com/RPi-Distro/firmware-nonfree/$_commitid_wl/brcm/brcmfmac43455-sdio.clm_blob"
|
||||||
"https://raw.githubusercontent.com/RPi-Distro/firmware-nonfree/$_commitid_wl/brcm/brcmfmac43455-sdio.txt"
|
"https://raw.githubusercontent.com/RPi-Distro/firmware-nonfree/$_commitid_wl/brcm/brcmfmac43455-sdio.txt"
|
||||||
|
"https://raw.githubusercontent.com/RPi-Distro/firmware-nonfree/$_commitid_wl/brcm/brcmfmac43455-sdio.bin"
|
||||||
"https://raw.githubusercontent.com/RPi-Distro/bluez-firmware/$_commitid_bt/broadcom/BCM4345C0.hcd")
|
"https://raw.githubusercontent.com/RPi-Distro/bluez-firmware/$_commitid_bt/broadcom/BCM4345C0.hcd")
|
||||||
sha256sums=('8e2250518bc789e53109728c3c0a6124bc3801a75a1cb4966125753cf1f0252e'
|
sha256sums=('8e2250518bc789e53109728c3c0a6124bc3801a75a1cb4966125753cf1f0252e'
|
||||||
'bddee0eff55a11e939e000ad341c951c7ee67758fc26b838b0472792aed33639'
|
'bddee0eff55a11e939e000ad341c951c7ee67758fc26b838b0472792aed33639'
|
||||||
|
'0f1817f50649df707f521dec9f2d5905e4c01939c8aabfa9a06b2ce0a36952ee'
|
||||||
'd09ce049f65619f007d604069d2b4d2a3ffe3cf897245287ef379955ce3969de')
|
'd09ce049f65619f007d604069d2b4d2a3ffe3cf897245287ef379955ce3969de')
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
install -d "${pkgdir}/usr/lib/firmware/brcm"
|
install -d "${pkgdir}/usr/lib/firmware/updates/brcm"
|
||||||
install -m 0644 *.hcd *.txt *.clm_blob "${pkgdir}/usr/lib/firmware/brcm"
|
install -m 0644 *.hcd *.txt *.bin *.clm_blob "${pkgdir}/usr/lib/firmware/updates/brcm"
|
||||||
install -m 0644 brcmfmac43455-sdio.txt "${pkgdir}/usr/lib/firmware/brcm/brcmfmac43455-sdio.phicomm,n1.txt"
|
install -m 0644 brcmfmac43455-sdio.txt "${pkgdir}/usr/lib/firmware/updates/brcm/brcmfmac43455-sdio.phicomm,n1.txt"
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,8 +16,8 @@ post_upgrade() {
|
||||||
mac=$(sed 's/^.*\(..\)\(..\)\(..\)\(..\)\(..\)\(..\)$/\1:\2:\3:\4:\5:\6/' < /etc/machine-id)
|
mac=$(sed 's/^.*\(..\)\(..\)\(..\)\(..\)\(..\)\(..\)$/\1:\2:\3:\4:\5:\6/' < /etc/machine-id)
|
||||||
grep -qiE '([0-9a-f][0-9a-f]:){5}[0-9a-f][0-9a-f]' <<< "$mac" || exit 1
|
grep -qiE '([0-9a-f][0-9a-f]:){5}[0-9a-f][0-9a-f]' <<< "$mac" || exit 1
|
||||||
fi
|
fi
|
||||||
sed -i "s/^macaddr=.*$/macaddr=${mac}/g" /usr/lib/firmware/brcm/brcmfmac43455-sdio.phicomm,n1.txt
|
sed -i "s/^macaddr=.*$/macaddr=${mac}/g" /usr/lib/firmware/updates/brcm/brcmfmac43455-sdio.phicomm,n1.txt
|
||||||
# set bluetooth macaddr
|
# set bluetooth macaddr
|
||||||
echo -en $(sed 's/^.*:\(..\):\(..\):\(..\)$/\\x\3\\x\2\\x\1/' <<< "$mac") | \
|
echo -en $(sed 's/^.*:\(..\):\(..\):\(..\)$/\\x\3\\x\2\\x\1/' <<< "$mac") | \
|
||||||
dd of=/usr/lib/firmware/brcm/BCM4345C0.hcd bs=1 seek=$((0x21)) count=3 conv=notrunc status=none
|
dd of=/usr/lib/firmware/updates/brcm/BCM4345C0.hcd bs=1 seek=$((0x21)) count=3 conv=notrunc status=none
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue