Gentoo Archives: gentoo-commits

From: "Diego Petteno (flameeyes)" <flameeyes@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in media-sound/pulseaudio/files: pulseaudio.init.d-3 digest-pulseaudio-0.9.6-r2
Date: Fri, 26 Oct 2007 15:28:50
Message-Id: E1IlR76-0005WL-TG@stork.gentoo.org
1 flameeyes 07/10/26 15:28:44
2
3 Added: pulseaudio.init.d-3 digest-pulseaudio-0.9.6-r2
4 Log:
5 Add a new revision with an experimental init script with dynamic dependencies. With this script, disabling HAL or Avahi support on the configuration file will not require them to be started even if PulseAudio was built with their support enabled. Similarly ALSA is no more a requirement if no ALSA sink or source is defined and no autodetect modules are loaded.
6 (Portage version: 2.1.3.16)
7
8 Revision Changes Path
9 1.1 media-sound/pulseaudio/files/pulseaudio.init.d-3
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3?rev=1.1&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3?rev=1.1&content-type=text/plain
13
14 Index: pulseaudio.init.d-3
15 ===================================================================
16 #!/sbin/runscript
17 # Copyright 1999-2004 Gentoo Foundation
18 # Distributed under the terms of the GNU General Public License v2
19 # $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3,v 1.1 2007/10/26 15:28:44 flameeyes Exp $
20
21 depend() {
22 use net
23
24 local script="/etc/pulse/default.pa"
25
26 for opt in ${PA_OPTS}; do
27 case "$opt" in
28 --file=*) script="${opt#*=}" ;;
29 -F*) script="${opt#-F}" ;;
30 esac
31 done
32
33 config "$script"
34
35 local needs="$(get_options need)"
36 if [ -n "${needs}" ]; then
37 need ${needs}
38 return
39 fi
40
41 #ifdef HAL
42 if egrep -q '^[[:space:]]*load-module[[:space:]]+module-hal-detect' "$script"; then
43 needs="${needs} hald"
44 fi
45 #endif
46
47 #ifdef AVAHI
48 if egrep -q '[[:space:]]*load-module[[:space:]]+module-zeroconf-publish' "$script"; then
49 needs="${needs} avahi-daemon"
50 fi
51 #endif
52
53 #ifdef ALSA
54 if egrep -q '[[:space:]]*load-module[[:space:]]+module-alsa-(sink|source)' "$script" ||
55 egrep -q '[[:space:]]*load-module[[:space:]]+module-(hal-)?detect' "$script" ||
56 egrep -q '[[:space:]]*add-autoload-source[[:space:]]+(input|output)[[:space:]]+module-alsa-(sink|source)' "$script"; then
57 needs="${needs} alsasound"
58 fi
59 #endif
60
61 need "${needs}"
62 save_options need "${needs}"
63 }
64
65 start() {
66 ebegin "Starting pulseaudio"
67 PA_ALL_OPTS="${PA_OPTS} --fail=1 --daemonize=1 --system"
68 start-stop-daemon --start --exec /usr/bin/pulseaudio -- ${PA_ALL_OPTS}
69 eend $?
70 }
71
72 stop() {
73 ebegin "Stopping pulseaudio"
74 start-stop-daemon --stop --quiet --exec /usr/bin/pulseaudio --pidfile /var/run/pulse/pid
75 eend $?
76 }
77
78
79
80 1.1 media-sound/pulseaudio/files/digest-pulseaudio-0.9.6-r2
81
82 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/digest-pulseaudio-0.9.6-r2?rev=1.1&view=markup
83 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/digest-pulseaudio-0.9.6-r2?rev=1.1&content-type=text/plain
84
85 Index: digest-pulseaudio-0.9.6-r2
86 ===================================================================
87 MD5 669d52a70fb9a7a83c2507005bfa2a6f pulseaudio-0.9.6.tar.gz 1157647
88 RMD160 04de5538d6f4530f90163ba52b6f077878f1297b pulseaudio-0.9.6.tar.gz 1157647
89 SHA256 b7a5f14eb8cf7076f1df8fb78d4a05c83e1e655474688c48364fa1b96f478d64 pulseaudio-0.9.6.tar.gz 1157647
90
91
92
93 --
94 gentoo-commits@g.o mailing list