Accepting request 23382 from home:lnussel:branches:openSUSE:Factory
Copy from home:lnussel:branches:openSUSE:Factory/pulseaudio via accept of submit request 23382 revision 2. Request was accepted with message: reviewed ok. OBS-URL: https://build.opensuse.org/request/show/23382 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/pulseaudio?expand=0&rev=26
This commit is contained in:
parent
1a0e4ba1e9
commit
1f50d2c672
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Oct 29 09:33:55 UTC 2009 - lnussel@suse.de
|
||||||
|
|
||||||
|
- clean up and fix setup-pulseaudio to not corrupt /etc/environment
|
||||||
|
(bnc#547384)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Oct 6 19:10:19 UTC 2009 - sreeves@novell.com
|
Tue Oct 6 19:10:19 UTC 2009 - sreeves@novell.com
|
||||||
|
|
||||||
|
@ -5,12 +5,13 @@ LIST_OF_OSS_APPS="aumix sox"
|
|||||||
show_help() {
|
show_help() {
|
||||||
echo "setup-pulseaudio [ --enable | --disable | --status ]"
|
echo "setup-pulseaudio [ --enable | --disable | --status ]"
|
||||||
echo ""
|
echo ""
|
||||||
echo "Sets up PulseAudio configuration for all sound-based applications"
|
echo "Modifies configuration files of some applications for PulseAudio"
|
||||||
echo " --enable Enables PulseAudio"
|
echo " --enable Enables PulseAudio"
|
||||||
echo " --disable Disables PulseAudio"
|
echo " --disable Disables PulseAudio"
|
||||||
echo " --status Shows activation state (disabled or enabled) for PulseAudio"
|
echo " --status Shows activation state (disabled or enabled) for PulseAudio"
|
||||||
echo ""
|
echo ""
|
||||||
echo "You need to be root for this command to succeed"
|
echo "You need to be root for this command to succeed"
|
||||||
|
echo "You may need to re-login for changes to take effect"
|
||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -48,27 +49,28 @@ enable_libao() {
|
|||||||
|
|
||||||
enable_mplayer() {
|
enable_mplayer() {
|
||||||
echo "Enabling PulseAudio for mplayer..."
|
echo "Enabling PulseAudio for mplayer..."
|
||||||
# Maybe it would be better to just add a alias mplayer=mplayer -ao pulse to /etc/environment?
|
|
||||||
if test -f /etc/mplayer/mplayer.conf; then
|
if test -f /etc/mplayer/mplayer.conf; then
|
||||||
if grep "ao=pulse" /etc/mplayer/mplayer.conf; then
|
if grep -q '^ao=' /etc/mplayer/mplayer.conf; then
|
||||||
echo "Default driver is pulse already in /etc/mplayer/mplayer.conf"
|
perl -pi -e "s|^ao=.*|ao=pulse|g;" /etc/pulse/client.conf
|
||||||
else
|
else
|
||||||
echo ""
|
echo "ao=pulse" >> /etc/mplayer/mplayer.conf
|
||||||
fi
|
fi
|
||||||
else
|
|
||||||
echo "ao=pulse" >> /etc/mplayer/mplayer.conf
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# FIXME: mplayerplug-in uses $HOME/.mplayer/mplayerplug-in.conf
|
# FIXME: mplayerplug-in uses $HOME/.mplayer/mplayerplug-in.conf
|
||||||
}
|
}
|
||||||
|
|
||||||
enable_openal() {
|
enable_openal() {
|
||||||
echo "Enabling PulseAudio for openal..."
|
# nothing to do here. openal-soft is patched to prefer pulse but
|
||||||
# FIXME: openal uses ~/.openalrc
|
# it won't autostart the daemon.
|
||||||
echo ""
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
enable_oss() {
|
enable_oss() {
|
||||||
|
# this is broken. /etc/environment must only contain environment
|
||||||
|
# variables. It's not a shell script
|
||||||
|
return 0
|
||||||
|
|
||||||
echo "Enabling PulseAudio for OSS..."
|
echo "Enabling PulseAudio for OSS..."
|
||||||
for app in $LIST_OF_OSS_APPS; do
|
for app in $LIST_OF_OSS_APPS; do
|
||||||
if grep "alias $app=padsp $app" /etc/environment; then
|
if grep "alias $app=padsp $app" /etc/environment; then
|
||||||
@ -90,6 +92,10 @@ enable_sdl() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
enable_timidity() {
|
enable_timidity() {
|
||||||
|
# this is broken. /etc/environment must only contain environment
|
||||||
|
# variables. It's not a shell script
|
||||||
|
return 0
|
||||||
|
|
||||||
echo "Enabling PulseAudio for Timidity..."
|
echo "Enabling PulseAudio for Timidity..."
|
||||||
# Use esound output for timidity
|
# Use esound output for timidity
|
||||||
if grep "alias timidity=timidity -Oe" /etc/environment; then
|
if grep "alias timidity=timidity -Oe" /etc/environment; then
|
||||||
@ -100,9 +106,9 @@ enable_timidity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
enable_xine() {
|
enable_xine() {
|
||||||
echo "Enabling PulseAudio for Xine..."
|
#echo "Enabling PulseAudio for Xine..."
|
||||||
# FIXME: xine uses $HOME/.xine/config
|
# FIXME: xine uses $HOME/.xine/config
|
||||||
echo ""
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
enable_autospawn() {
|
enable_autospawn() {
|
||||||
@ -120,27 +126,30 @@ disable_alsa() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
disable_libao() {
|
disable_libao() {
|
||||||
echo "Disabling PulseAudio for libao..."
|
|
||||||
if test -f /etc/libao.conf; then
|
if test -f /etc/libao.conf; then
|
||||||
|
echo "Disabling PulseAudio for libao..."
|
||||||
perl -pi -e "s|default_driver=pulse||g;" /etc/libao.conf
|
perl -pi -e "s|default_driver=pulse||g;" /etc/libao.conf
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_mplayer() {
|
disable_mplayer() {
|
||||||
echo "Disabling PulseAudio for mplayer..."
|
|
||||||
if test -f /etc/mplayer/mplayer.conf; then
|
if test -f /etc/mplayer/mplayer.conf; then
|
||||||
|
echo "Disabling PulseAudio for mplayer..."
|
||||||
perl -pi -e "s|ao=pulse||g;" /etc/mplayer/mplayer.conf
|
perl -pi -e "s|ao=pulse||g;" /etc/mplayer/mplayer.conf
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_openal() {
|
disable_openal() {
|
||||||
echo "Disabling PulseAudio for openal..."
|
# nothing to do here. openal-soft is patched to prefer pulse but
|
||||||
# FIXME: openal uses ~/.openalrc
|
# it won't autostart the daemon.
|
||||||
echo ""
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_oss() {
|
disable_oss() {
|
||||||
echo "Disabling PulseAudio for OSS..."
|
# this is broken. /etc/environment must only contain environment
|
||||||
|
# variables. It's not a shell script
|
||||||
|
return 0
|
||||||
|
|
||||||
for app in $LIST_OF_OSS_APPS; do
|
for app in $LIST_OF_OSS_APPS; do
|
||||||
perl -pi -e "s|alias $app=padsp $app||g;" /etc/environment
|
perl -pi -e "s|alias $app=padsp $app||g;" /etc/environment
|
||||||
done
|
done
|
||||||
@ -154,14 +163,18 @@ disable_sdl() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
disable_timidity() {
|
disable_timidity() {
|
||||||
|
# this is broken. /etc/environment must only contain environment
|
||||||
|
# variables. It's not a shell script
|
||||||
|
return 0
|
||||||
|
|
||||||
echo "Disabling PulseAudio for Timidity..."
|
echo "Disabling PulseAudio for Timidity..."
|
||||||
perl -pi -e "s|alias timidity=timidity -Oe||g;" /etc/environment
|
perl -pi -e "s|alias timidity=timidity -Oe||g;" /etc/environment
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_xine() {
|
disable_xine() {
|
||||||
echo "Disabling PulseAudio for Xine..."
|
#echo "Disabling PulseAudio for Xine..."
|
||||||
# FIXME: xine uses $HOME/.xine/config
|
# FIXME: xine uses $HOME/.xine/config
|
||||||
echo ""
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_autospawn() {
|
disable_autospawn() {
|
||||||
|
Loading…
Reference in New Issue
Block a user