forked from atar-axis/xpadneo
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·32 lines (21 loc) · 1.01 KB
/
Copy pathinstall.sh
File metadata and controls
executable file
·32 lines (21 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash
cd "$(dirname "$0")"
source "lib/options.sh"
source "lib/installer.sh"
set -e
if [[ ! -d /sys/devices/virtual/misc/uhid ]]; then
>&2 echo 'WARNING: Kernel uhid module not found, controller firmware 5.x may not be supported.'
>&2 echo 'WARNING: This does not prevent xpadneo from being installed. If your kernel supports'
>&2 echo 'WARNING: uhid, loading hid_xpadneo during boot should also load uhid; see'
>&2 echo 'WARNING: `docs/TROUBLESHOOTING.md` for the `/etc/modules-load.d/xpadneo.conf`'
>&2 echo 'WARNING: example.'
fi
if [ "$(uname -r | awk -F. '{ printf "%03d%03d",$1,$2 }')" -lt 005012 ]; then
>&2 echo "WARNING: kernel 5.12 or lower will not be supported due to known ERTM issues"
fi
echo "* deploying DKMS package"
make "${MAKE_OPTS[@]}" VERSION="${VERSION}" install || maybe_already_installed
echo "* building module"
dkms build "${V[@]}" "hid-xpadneo/${VERSION}" || cat_dkms_make_log
echo "* installing module"
dkms install "${V[@]}" "${FORCE}" "hid-xpadneo/${VERSION}"