~ubuntu-branches/ubuntu/vivid/oss4/vivid-proposed

« back to all changes in this revision

Viewing changes to setup/SCO_SV/oss/build/install.sh

  • Committer: Bazaar Package Importer
  • Author(s): Romain Beauxis, Samuel Thibault, Romain Beauxis, Sebastien NOEL
  • Date: 2011-06-14 10:06:56 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20110614100656-cx4oc7u426zn812z
Tags: 4.2-build2004-1
[ Samuel Thibault ]
* debian/control: Add liboss4-salsa2, liboss4-salsa-dev and
  liboss4-salsa-asound2 packages, equivalent to (and will replace) those from
  the oss-libsalsa package (Closes: #589127).
* debian/patches/liboss4-salsa.patch: New patch to rename libsalsa into
  liboss4-salsa to avoid conflicts in the archive for no good reason.
* debian/rules: Make in libOSSlib and libsalsa.
* debian/liboss4-salsa-dev.install, debian/liboss4-salsa2.install,
  debian/liboss4-salsa-asound2.links, debian/liboss4-salsa-dev.links:
  Install liboss4-salsa libraries like was done in the oss-libsalsa package.
* include-alsa: Add a copy of ALSA 1.0.5 headers: Cf ALSA_1.0.* symbols in
  libsalsa, this is the roughly supported version.
* debian/copyright: Update for new include-alsa files.
* alsa.pc: New file for compatibility with libasound-dev.
* debian/control:
  - Add Vcs-Browser and Vcs-Svn fields.
  - Use linux-any instead of the list of Linux archs (Closes: #604679).
  - Make dkms dependency linux-any only.
* debian/patches/hurd_iot.patch: New patch to fix soundcard.h usage in
  libsalsa on hurd-i386.
* debian/patches/libsalsa_fixes.patch: New patch to fix some printf usages
  and ioctl declaration in libsalsa.
* debian/patches/no_EBADE.patch: New patch to cope with hurd-i386 not having
  EBADE.
* debian/patches/CFLAGS.patch: New patch to make oss4 take debian/rules
  CFLAGS into account.
* debian/patches/snd_asoundlib_version.patch: New patch to add
  snd_asoundlib_version().
* debian/patches/generic_srccconf.patch: New patch to fix source
  configuration on unknown archs.

[ Romain Beauxis ]
* Fixed README.Debian to only mention dkms' modules.
* Switch to dpkg-source 3.0 (quilt) format
* Added DM-Upload-Allowed: yes

[ Sebastien NOEL ]
* New upstream release (Closes: #595298, #619272).
* Fix typo in initscript (Closes: #627149).
* debian/control: adjust linux-headers dependencies (Closes: #628879).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
 
 
3
. /etc/oss.conf
 
4
 
 
5
if test "$CONFDIR " = " "
 
6
then
 
7
  CONFDIR=/etc/conf
 
8
fi
 
9
 
 
10
# Remove the non-oss ICH driver before doing anything else
 
11
/etc/conf/bin/idinstall -R $CONFDIR -d ich > /dev/null 2>&1
 
12
 
 
13
# Unload previous modules
 
14
for n in `ls $OSSLIBDIR/modules|egrep -v "osscore|oss_imux"`
 
15
do
 
16
  modadmin -U $n > /dev/null 2>&1
 
17
done
 
18
 
 
19
for MOD in osscore oss_imux
 
20
do
 
21
  modadmin -U $MOD > /dev/null 2>&1
 
22
done
 
23
 
 
24
# (re)install osscore and oss_imux
 
25
 
 
26
rm -f $OSSLIBDIR/modules/*/install.log
 
27
 
 
28
for MOD in osscore oss_imux
 
29
do
 
30
  cd $OSSLIBDIR/modules/$MOD
 
31
 
 
32
  if test ! -f Space.c
 
33
  then
 
34
     cp $OSSLIBDIR/space.inst/$MOD Space.c
 
35
  fi
 
36
 
 
37
  rm -f install.log
 
38
  
 
39
  if /etc/conf/bin/idinstall -k -P oss -R $CONFDIR -M $MOD >> install.log 2>&1
 
40
  then
 
41
    if /etc/conf/bin/idbuild -M $MOD >> install.log 2>&1
 
42
    then
 
43
      echo OSS module $MOD installed OK
 
44
      echo OSS module $MOD installed OK >> install.log
 
45
    else
 
46
      cat install.log
 
47
      echo Building $MOD module failed
 
48
      echo Building $MOD module failed >> install.log
 
49
      exit 1
 
50
    fi
 
51
  else
 
52
    cat install.log
 
53
    echo Failed to idinstall $MOD
 
54
    echo Failed to idinstall $MOD >> install.log
 
55
    exit 1
 
56
  fi
 
57
 
 
58
  (cd $OSSLIBDIR/conf && rm -f $MOD.conf && ln -sf ../modules/$MOD/Space.c $MOD.conf)
 
59
 
 
60
  installf oss $CONFDIR/sdevice.d/$MOD
 
61
done
 
62
 
 
63
 
 
64
# Only install the drivers we have a resmgr match for
 
65
OSSTMPFILE=/tmp/ossdetect.$$
 
66
CDIR=`pwd`
 
67
cd $OSSLIBDIR/modules
 
68
/sbin/resmgr -p BRDID > $OSSTMPFILE
 
69
for file in */Drvmap
 
70
do
 
71
        DRVR=`dirname $file`
 
72
        grep "^|" $file | cut -d \| -f3 | while read BRDID
 
73
        do
 
74
                if [ -n "$BRDID" ]; then
 
75
                        while read RMBRDID
 
76
                        do
 
77
                                if [ "$BRDID" = "$RMBRDID" ]; then
 
78
                                        echo "$DRVR"
 
79
                                fi
 
80
                        done < $OSSTMPFILE
 
81
                fi
 
82
        done
 
83
done | sort -u | while read DRVR
 
84
do
 
85
  cd $OSSLIBDIR/modules/$DRVR
 
86
 
 
87
  if test ! -f Space.c
 
88
  then
 
89
     cp $OSSLIBDIR/../space.inst/$n Space.c
 
90
  fi
 
91
 
 
92
  rm -f install.log
 
93
 
 
94
# /etc/conf/bin/idinstall -R $CONFDIR -d $DRVR > /dev/null 2>&1
 
95
 
 
96
  if /etc/conf/bin/idinstall -k -P oss -R $CONFDIR -M $DRVR >> install.log 2>&1
 
97
  then
 
98
    if /etc/conf/bin/idbuild -M $DRVR >> install.log 2>&1
 
99
    then
 
100
      echo OSS module $DRVR installed OK
 
101
      echo OSS module $DRVR installed OK >> install.log
 
102
    else
 
103
      cat install.log
 
104
      echo Building $DRVR module failed
 
105
      echo Building $DRVR module failed >> install.log
 
106
      exit 1
 
107
    fi
 
108
  else
 
109
    cat install.log
 
110
    echo Failed to idinstall $DRVR
 
111
    echo Failed to idinstall $DRVR >> install.log
 
112
    exit 1
 
113
  fi
 
114
  installf oss $CONFDIR/sdevice.d/$DRVR
 
115
 
 
116
  (cd $OSSLIBDIR/conf && rm -f $DRVR.conf && \
 
117
         ln -sf ../modules/$DRVR/Space.c $DRVR.conf)
 
118
done
 
119
 
 
120
rm -f $OSSTMPFILE
 
121
 
 
122
cd $CDIR
 
123
 
 
124
if test -f /bin/dcu
 
125
then
 
126
  /bin/dcu -S
 
127
else
 
128
  /sbin/dcu -S
 
129
fi
 
130
 
 
131
if test ! -f $OSSLIBDIR/etc/installed_drivers
 
132
then
 
133
echo "----------------------------------------------"
 
134
        /usr/sbin/ossdetect -v
 
135
echo "----------------------------------------------"
 
136
fi
 
137
echo OSS modules installed OK