public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in media-sound/pulseaudio/files: pulseaudio.init.d-3 digest-pulseaudio-0.9.6-r2
@ 2007-10-26 15:28 Diego Petteno (flameeyes)
  0 siblings, 0 replies; only message in thread
From: Diego Petteno (flameeyes) @ 2007-10-26 15:28 UTC (permalink / raw
  To: gentoo-commits

flameeyes    07/10/26 15:28:44

  Added:                pulseaudio.init.d-3 digest-pulseaudio-0.9.6-r2
  Log:
  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.
  (Portage version: 2.1.3.16)

Revision  Changes    Path
1.1                  media-sound/pulseaudio/files/pulseaudio.init.d-3

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3?rev=1.1&content-type=text/plain

Index: pulseaudio.init.d-3
===================================================================
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/files/pulseaudio.init.d-3,v 1.1 2007/10/26 15:28:44 flameeyes Exp $

depend() {
	use net

	local script="/etc/pulse/default.pa"

	for opt in ${PA_OPTS}; do
		case "$opt" in
			--file=*)	script="${opt#*=}" ;;
			-F*)		script="${opt#-F}" ;;
		esac
	done

	config "$script"

	local needs="$(get_options need)"
	if [ -n "${needs}" ]; then
		need ${needs}
		return
	fi

#ifdef HAL
	if egrep -q '^[[:space:]]*load-module[[:space:]]+module-hal-detect' "$script"; then
	    needs="${needs} hald"
	fi
#endif

#ifdef AVAHI
	if egrep -q '[[:space:]]*load-module[[:space:]]+module-zeroconf-publish' "$script"; then
	    needs="${needs} avahi-daemon"
	fi
#endif

#ifdef ALSA
	if egrep -q '[[:space:]]*load-module[[:space:]]+module-alsa-(sink|source)' "$script" || 
	    egrep -q '[[:space:]]*load-module[[:space:]]+module-(hal-)?detect' "$script" ||
	    egrep -q '[[:space:]]*add-autoload-source[[:space:]]+(input|output)[[:space:]]+module-alsa-(sink|source)' "$script"; then
	    needs="${needs} alsasound"
	fi
#endif

	need "${needs}"
	save_options need "${needs}"
}

start() {
	ebegin "Starting pulseaudio"
	PA_ALL_OPTS="${PA_OPTS} --fail=1 --daemonize=1 --system"
	start-stop-daemon --start --exec /usr/bin/pulseaudio -- ${PA_ALL_OPTS}
	eend $?
}

stop() {
	ebegin "Stopping pulseaudio"
	start-stop-daemon --stop --quiet --exec /usr/bin/pulseaudio --pidfile /var/run/pulse/pid
	eend $?
}



1.1                  media-sound/pulseaudio/files/digest-pulseaudio-0.9.6-r2

file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-sound/pulseaudio/files/digest-pulseaudio-0.9.6-r2?rev=1.1&view=markup
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

Index: digest-pulseaudio-0.9.6-r2
===================================================================
MD5 669d52a70fb9a7a83c2507005bfa2a6f pulseaudio-0.9.6.tar.gz 1157647
RMD160 04de5538d6f4530f90163ba52b6f077878f1297b pulseaudio-0.9.6.tar.gz 1157647
SHA256 b7a5f14eb8cf7076f1df8fb78d4a05c83e1e655474688c48364fa1b96f478d64 pulseaudio-0.9.6.tar.gz 1157647



-- 
gentoo-commits@gentoo.org mailing list



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-10-26 15:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-26 15:28 [gentoo-commits] gentoo-x86 commit in media-sound/pulseaudio/files: pulseaudio.init.d-3 digest-pulseaudio-0.9.6-r2 Diego Petteno (flameeyes)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox