File: removeoss.sh

package info (click to toggle)
oss4 4.2-build2020-4
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 16,408 kB
  • sloc: ansic: 237,053; cpp: 18,981; sh: 4,909; pascal: 3,863; asm: 1,189; makefile: 646; php: 53; xml: 46
file content (31 lines) | stat: -rw-r--r-- 626 bytes parent folder | download | duplicates (4)
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
#!/bin/sh
if test `whoami` != "root"
then
  echo "You must be super-user or logged in as root to uninstall OSS..."
  exit 0
fi

if test -f /etc/oss.conf
then
  . /etc/oss.conf
else
  OSSLIBDIR=/usr/lib/oss
fi

echo "Uninstalling OSS...."
echo "Running soundoff...."
/usr/sbin/soundoff
echo "Restoring previously install sound drivers..."
sh "$OSSLIBDIR"/scripts/restore_drv.sh
echo "Removing OSS Files in MANIFEST"
cd /
for i in `cat "$OSSLIBDIR"/MANIFEST`
do
# echo "Removing file $i"
rm -f $i
done

echo "Removing $OSSLIBDIR directory"
rm -rf "$OSSLIBDIR"

echo "OSS Uninstalled. However you may need to reboot the system."