OBS User unknown 2008-11-20 15:17:26 +00:00 committed by Git OBS Bridge
parent 880ba08033
commit 0168d8f9d8
4 changed files with 51 additions and 2 deletions

20
pulseaudio-asserts.patch Normal file
View File

@ -0,0 +1,20 @@
Index: src/modules/module-alsa-source.c
===================================================================
--- src/modules/module-alsa-source.c.orig
+++ src/modules/module-alsa-source.c
@@ -1280,9 +1280,12 @@ int pa__init(pa_module*m) {
VALGRIND_MAKE_MEM_DEFINED(&u->hw_dB_max, sizeof(u->hw_dB_max));
#endif
- pa_log_info("Volume ranges from %0.2f dB to %0.2f dB.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
- pa_assert(u->hw_dB_min < u->hw_dB_max);
- u->hw_dB_supported = TRUE;
+ if (u->hw_dB_min >= u->hw_dB_max)
+ pa_log_warn("Your kernel driver is broken: it reports a volume range from %0.2f dB to %0.2f dB which makes no sense.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
+ else {
+ pa_log_info("Volume ranges from %0.2f dB to %0.2f dB.", (double) u->hw_dB_min/100.0, (double) u->hw_dB_max/100.0);
+ u->hw_dB_supported = TRUE;
+ }
}
if (suitable &&

View File

@ -1,3 +1,13 @@
-------------------------------------------------------------------
Wed Nov 19 13:14:25 CET 2008 - rodrigo@novell.com
- Some fixes in setup-pulseaudio script (bnc#445015)
-------------------------------------------------------------------
Wed Nov 19 12:38:46 CET 2008 - rodrigo@novell.com
- Add upstream patch for bnc#443510
-------------------------------------------------------------------
Tue Nov 11 19:32:04 CET 2008 - rodrigo@novell.com

View File

@ -22,7 +22,7 @@ Name: pulseaudio
%define drvver 0.9
Summary: A Networked Sound Server
Version: 0.9.12
Release: 7
Release: 8
License: GPL v2 or later; LGPL v2.1 or later
Group: System/Sound Daemons
Source: %{name}-%{version}.tar.bz2
@ -40,6 +40,8 @@ Patch3: pulseaudio-defaults-daemon-conf.patch
Patch4: pulseaudio-dot-pulse.patch
# PATCH-FIX-UPSTREAM pulseaudio-allow-in-sample-names.patch bnc#439054
Patch5: pulseaudio-allow-in-sample-names.patch
# PATCH-FIX-UPSTREAM pulseaudio-asserts.patch bnc#443510 rodrigo@novell.com
Patch6: pulseaudio-asserts.patch
%description
pulseaudio is a networked sound server for Linux and other Unix like
@ -319,6 +321,7 @@ Authors:
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p0
%build
autoreconf -fi
@ -545,6 +548,10 @@ groupadd -r pulse-access &>/dev/null || :
%{_mandir}/man1/pax11publish.1.gz
%changelog
* Wed Nov 19 2008 rodrigo@novell.com
- Some fixes in setup-pulseaudio script (bnc#445015)
* Wed Nov 19 2008 rodrigo@novell.com
- Add upstream patch for bnc#443510
* Tue Nov 11 2008 rodrigo@novell.com
- Add upstream patch for bnc#439054
* Mon Oct 27 2008 rodrigo@novell.com

View File

@ -227,6 +227,18 @@ case $1 in
esac
# Now, update /etc/sysconfig/sound with the PA status
perl -pi -e "s|PULSEAUDIO_ENABLE=\"no\"|PULSEAUDIO_ENABLE=\"yes\"|g;" /etc/sysconfig/sound
if grep PULSEAUDIO_ENABLE /etc/sysconfig/sound; then
if [ "x$ENABLE" = "x1" ]; then
perl -pi -e "s|PULSEAUDIO_ENABLE=\"no\"|PULSEAUDIO_ENABLE=\"yes\"|g;" /etc/sysconfig/sound
else
perl -pi -e "s|PULSEAUDIO_ENABLE=\"yes\"|PULSEAUDIO_ENABLE=\"no\"|g;" /etc/sysconfig/sound
fi
else
if [ "x$ENABLE" = "x1" ]; then
echo "PULSEAUDIO_ENABLE=\"yes\"" >> /etc/sysconfig/sound
else
echo "PULSEAUDIO_ENABLE=\"no\"" >> /etc/sysconfig/sound
fi
fi
/sbin/SuSEconfig