/[gentoo-x86]/net-wireless/bluez/files/bluez-4.18-udev.script
Gentoo

Contents of /net-wireless/bluez/files/bluez-4.18-udev.script

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Fri Nov 28 21:21:36 2008 UTC (6 years ago) by dev-zero
Branch: MAIN
Initial commit, keeping the keywords the same as for bluez-libs/-utils since it's mostly the same. Most patches are taken from bluez-libs/-utils. (bug #236357)
(Portage version: 2.2_rc16/cvs/Linux 2.6.27.5 x86_64)

1 dev-zero 1.1 #!/bin/sh
2     #
3     # bluetooth.sh: udev external RUN script
4     #
5     # Copyright:
6     # 2005-2006 Henrik Brix Andersen <brix@gentoo.org>
7     # 2007 Petteri Räty <betelgeuse@gentoo.org>
8     # 2008 Tiziano Müller <dev-zero@gentoo.org>
9     # Distributed under the terms of the GNU General Public License v2
10    
11     script=/etc/init.d/bluetooth
12    
13     # Find out where sysfs is mounted. Exit if not available
14     sysfs=`grep -F sysfs /proc/mounts | awk '{print $2}'`
15     if [ "$sysfs" = "" ]; then
16     echo "sysfs is required"
17     exit 1
18     fi
19    
20     if [ ! -d $sysfs/class/bluetooth/hci[0-9]* -a ! -d $sysfs/bus/bluetooth/devices/hci[0-9]* ]; then
21     if $script --quiet status; then
22     IN_HOTPLUG=1 $script --quiet stop
23     fi
24     else
25     if ! $script --quiet status; then
26     IN_HOTPLUG=1 $script --quiet start
27     fi
28     fi

  ViewVC Help
Powered by ViewVC 1.1.20