summaryrefslogtreecommitdiff
path: root/multimedia/droidcam/doinst.sh
blob: 4c9ca035388c2a8cacec1f670208e9b7e46d20b1 (plain)
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
VERSION="1.8.2"
MODULE="v4l2loopback-dc"

if [ -x /usr/bin/update-desktop-database ]; then
  /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi

if [ -x /usr/bin/update-mime-database ]; then
  /usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1
fi

_installModule(){

    cp -r /tmp/SBo/$MODULE-$VERSION /usr/src/
    dkms add -m $MODULE -v $VERSION
    dkms build -m $MODULE -v $VERSION
    dkms install -m $MODULE -v $VERSION
    /sbin/modprobe $MODULE
    /sbin/modprobe snd-aloop
}

if [ "lsmod | grep v4l2loopback_dc" ]; then

    _installModule

else

    echo "Module v4l2loopback_dc installed"

fi