##// END OF EJS Templates
.
Unknown -
r467:85707c95183b
parent child
Show More
@@ -460,9 +460,9 else # BUILD_KERNEL=false
460 460 chown -R root:root "${R}"/tmp/kernel-header.deb
461 461
462 462 # Install kernel
463 chroot_exec dpkg -i "${R}"/tmp/kernel.deb
463 chroot_exec dpkg -i /tmp/kernel.deb
464 464 # Install kernel header
465 chroot_exec dpkg -i "${R}"/tmp/kernel-header.deb
465 chroot_exec dpkg -i /tmp/kernel-header.deb
466 466
467 467 # Remove temporary directory and files
468 468 rm -fr "${temp_dir}"
@@ -56,6 +56,10 if [ "$ENABLE_NEXMON" = true ] && [ "$ENABLE_WIRELESS" = true ]; then
56 56 ./configure
57 57 make
58 58
59 # Backup stock broadcom wlan driver - "${LIB_DIR}"/modules/${KERNEL_VERSION}/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko
60 brcmfmac_path=$(modinfo brcmfmac | grep -m 1 -oP "^filename:(\s*?)(.*)$" | sed -e 's/^filename:\(\s*\)\(.*\)$/\2/g')
61 mv "${brcmfmac_path}" "${brcmfmac_path}".orig
62
59 63 # build patches
60 64 if [ "$RPI_MODEL" = 0 ] || [ "$RPI_MODEL" = 3 ] ; then
61 65 cd "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon || exit
@@ -68,6 +72,8 if [ "$ENABLE_NEXMON" = true ] && [ "$ENABLE_WIRELESS" = true ]; then
68 72 mv "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.org.bin
69 73 cp "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac43430-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.nexmon.bin
70 74 cp -f "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac43430-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.bin
75
76 cp "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac_4.14.y-nexmon/brcmfmac.ko "${brcmfmac_path}"
71 77 fi
72 78
73 79 if [ "$RPI_MODEL" = 3P ] ; then
@@ -83,25 +89,7 if [ "$ENABLE_NEXMON" = true ] && [ "$ENABLE_WIRELESS" = true ]; then
83 89 cp -f "${NEXMON_ROOT}"/patches/bcm43455c0/7_45_154/nexmon/brcmfmac43455-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43455-sdio.bin
84 90 fi
85 91
86 # Install kernel module
87 "${LIB_DIR}"/modules/${KERNEL_VERSION}/
88
89 92 #Revert to previous directory
90 93 cd "${WORKDIR}" || exit
91 94
92 95 fi
93
94 ## To make the RPi load the modified driver after reboot
95 # Find the path of the default driver at reboot
96 # e.g. '/lib/modules/4.14.71-v7+/kernel/drivers/net/wireless/broadcom/brcm80211/brcmfmac/brcmfmac.ko'
97 PATH_OF_DEFAULT_DRIVER_AT_REBOOT=$(modinfo brcmfmac | grep -m 1 -oP "^filename:(\s*?)(.*)$" | sed -e 's/^filename:\(\s*\)\(.*\)$/\2/g')
98 # Backup the original driver
99 mv $PATH_OF_DEFAULT_DRIVER_AT_REBOOT "$PATH_OF_DEFAULT_DRIVER_AT_REBOOT.orig"
100 # Copy the modified driver (Kernel 4.14)
101 if is_pizero ; then
102 cp ./patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac_4.14.y-nexmon/brcmfmac.ko $PATH_OF_DEFAULT_DRIVER_AT_REBOOT
103 else
104 cp ./patches/bcm43455c0/7_45_154/nexmon/brcmfmac_4.14.y-nexmon/brcmfmac.ko $PATH_OF_DEFAULT_DRIVER_AT_REBOOT
105 fi
106 # Probe all modules and generate new dependency
107 depmod -a No newline at end of file
@@ -228,8 +228,8 COMPILER_PACKAGES=""
228 228 set +x
229 229
230 230 #Check if apt-cacher-ng has port 3142 open and set APT_PROXY
231 APT_CACHER_RUNNING=$(lsof -i :3142 | grep apt-cacher-ng | cut -d ' ' -f3 | uniq)
232 if [ -n "${APT_CACHER_RUNNING}" ] ; then
231 APT_CACHER_RUNNING=$(lsof -i :3142 | cut -d ' ' -f3 | uniq | sed '/^\s*$/d')
232 if [ "${APT_CACHER_RUNNING}" = "apt-cacher-ng" ] ; then
233 233 APT_PROXY=http://127.0.0.1:3142/
234 234 fi
235 235
General Comments 0
Vous devez vous connecter pour laisser un commentaire. Se connecter maintenant