Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bugzilla DB migration completed. Please report issues to Infra team via email via infra@gentoo.org or IRC
View | Details | Raw Unified | Return to bug 1797
Collapse All | Expand All

(-)/home/brianr/irda-utils-0.9.14/etc/gentoo/irda.conf (+6 lines)
Line 0 Link Here
1
#Set to yes to enable IRDA
2
IRDA=yes
3
IRDADEV=/dev/ttyS1
4
#Set (optional) Dongle name here
5
#DONGLE=actisys+
6
DISCOVERY=yes
(-)/home/brianr/irda-utils-0.9.14/etc/gentoo/irda.rc (+39 lines)
Line 0 Link Here
1
#!/sbin/runscript
2
# Copyright 1999-2002 Gentoo Technologies, Inc.
3
# Distributed under the terms of the GNU General Public License, v2 or later
4
5
checkconfig() {
6
        if [ -z "$IRDA" ] || [ -z "$IRDADEV" ] ; then
7
		eerror "You need to setup IRDA and IRDADEV in /etc/conf.d/irda first"
8
		return 1
9
	fi
10
}
11
12
start() {
13
	checkconfig || return 1
14
	
15
	# Check that irda is enabled.
16
	[ ${IRDA} = "no" ] && return 1
17
18
	[ -f /usr/sbin/irattach ] || return 1
19
20
	local ARGS=""
21
	if [ $DONGLE ]; then
22
		ARGS="$ARGS -d $DONGLE"
23
	fi
24
	if [ "$DISCOVERY" = "yes" ];then
25
		ARGS="$ARGS -s"
26
	fi
27
28
        # Attach irda device 
29
        ebegin "Starting IrDA"
30
        start-stop-daemon --start --quiet --pidfile /var/run/irda.pid \
31
                --exec /usr/sbin/irattach -- ${IRDADEV} ${ARGS}
32
	eend ${?}
33
}
34
	
35
stop() {
36
        ebegin "Shutting down IrDA"
37
	start-stop-daemon --stop --quiet --pidfile /var/run/irda.pid
38
	eend ${?}
39
}

Return to bug 1797