New Script: 88x2bu.sh: compile other wireless driver

This commit is contained in:
mollusk 2020-11-08 21:45:59 -07:00
parent 26c0e76abc
commit 8da16f9de6

36
88x2bu.sh Executable file
View File

@ -0,0 +1,36 @@
#!/bin/bash
GITHUB_REPO="https://github.com/RinCat/RTL88x2BU-Linux-Driver.git"
TEMPDIR="/tmp"
dependencies_(){
if [ -f /usr/bin/dnf ];then
dnf install make kernel-devel git
fi
}
clone_(){
if [ ! -d "${TEMPDIR}"/88xbu ];then
git clone "${GITHUB_REPO}" "${TEMPDIR}"/88xbu
fi
}
build_(){
if [ -d "${TEMPDIR}"/88xbu ];then
cd "${TEMPDIR}"/88xbu
make clean
make "${1}"
make install
else
echo "${TEMPDIR}/88xbu does not exist"
exit 1
fi
}
dependencies_
clone_
build_ "${1}"