Last active
April 30, 2018 13:46
-
-
Save SwagDevOps/b4a14db28885934336bb22adcfcdb4dd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env sh | |
| # ```sh | |
| # apt-get remove --purge bcmwl-kernel-source | |
| # cd /usr/local/src | |
| # git clone https://github.com/antoineco/broadcom-wl | |
| # ``` | |
| # Current regulatory domain. | |
| REG_COUNTRY=${REG_COUNTRY:-FR} | |
| # Path to broadcom-wl sources | |
| SOURCES_DIR=/usr/local/src/broadcom-wl | |
| # As installed by ``make install`` | |
| WIFI_MODULE=/lib/modules/$(uname -r)/kernel/drivers/net/wireless/wl.ko | |
| set -eu | |
| PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin | |
| # Notify the kernel about the current regulatory domain. | |
| sed -i "s/^REGDOMAIN=.*/REGDOMAIN=${REG_COUNTRY}/g" /etc/default/crda | |
| test -f "${WIFI_MODULE}" || { | |
| ( | |
| set -eu | |
| cd "${SOURCES_DIR}" | |
| make clean all install | |
| ) | |
| } | |
| chmod 644 "${WIFI_MODULE}" ||: | |
| depmod -A | |
| modprobe -rv bcma ssb b43 brcmsmac wl | |
| modprobe -v wl |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment