Hello community,
here is the log from the commit of package yast2-sound
checked in at Wed Oct 8 12:08:27 CEST 2008.
--------
--- yast2-sound/yast2-sound.changes 2008-10-06 17:23:42.000000000 +0200
+++ /mounts/work_src_done/STABLE/yast2-sound/yast2-sound.changes 2008-10-07 18:23:38.129673000 +0200
@@ -1,0 +2,7 @@
+Tue Oct 7 17:10:01 CEST 2008 - lslezak@suse.cz
+
+- use 'setup-pulseaudio' script for configuring PulseAudio
+ (bnc#425475)
+- 2.17.6
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
yast2-sound-2.17.5.tar.bz2
New:
----
yast2-sound-2.17.6.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-sound.spec ++++++
--- /var/tmp/diff_new_pack.O23947/_old 2008-10-08 12:07:57.000000000 +0200
+++ /var/tmp/diff_new_pack.O23947/_new 2008-10-08 12:07:57.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-sound (Version 2.17.5)
+# spec file for package yast2-sound (Version 2.17.6)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -19,12 +19,12 @@
Name: yast2-sound
-Version: 2.17.5
+Version: 2.17.6
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-sound-2.17.5.tar.bz2
+Source0: yast2-sound-2.17.6.tar.bz2
Prefix: /usr
BuildRequires: alsa-devel doxygen gcc-c++ perl-XML-Writer update-desktop-files yast2 yast2-core-devel yast2-devtools yast2-testsuite
# GetInstArgs::automatic_configuration
@@ -48,7 +48,7 @@
Dan Meszaros
%prep
-%setup -n yast2-sound-2.17.5
+%setup -n yast2-sound-2.17.6
%build
%{prefix}/bin/y2tool y2autoconf
@@ -94,6 +94,10 @@
/usr/share/YaST2/scrconf/*.scr
%doc %{prefix}/share/doc/packages/yast2-sound
%changelog
+* Tue Oct 07 2008 lslezak@suse.cz
+- use 'setup-pulseaudio' script for configuring PulseAudio
+ (bnc#425475)
+- 2.17.6
* Mon Oct 06 2008 lslezak@suse.cz
- fixed storing additional module parameters (bnc#404900)
(check the key before removal from a map)
++++++ yast2-sound-2.17.5.tar.bz2 -> yast2-sound-2.17.6.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/configure new/yast2-sound-2.17.6/configure
--- old/yast2-sound-2.17.5/configure 2008-10-06 17:22:55.000000000 +0200
+++ new/yast2-sound-2.17.6/configure 2008-10-07 18:22:45.000000000 +0200
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for yast2-sound 2.17.5.
+# Generated by GNU Autoconf 2.61 for yast2-sound 2.17.6.
#
# Report bugs to http://bugs.opensuse.org/.
#
@@ -728,8 +728,8 @@
# Identity of this package.
PACKAGE_NAME='yast2-sound'
PACKAGE_TARNAME='yast2-sound'
-PACKAGE_VERSION='2.17.5'
-PACKAGE_STRING='yast2-sound 2.17.5'
+PACKAGE_VERSION='2.17.6'
+PACKAGE_STRING='yast2-sound 2.17.6'
PACKAGE_BUGREPORT='http://bugs.opensuse.org/'
ac_unique_file="RPMNAME"
@@ -1446,7 +1446,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures yast2-sound 2.17.5 to adapt to many kinds of systems.
+\`configure' configures yast2-sound 2.17.6 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1517,7 +1517,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of yast2-sound 2.17.5:";;
+ short | recursive ) echo "Configuration of yast2-sound 2.17.6:";;
esac
cat <<\_ACEOF
@@ -1630,7 +1630,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-yast2-sound configure 2.17.5
+yast2-sound configure 2.17.6
generated by GNU Autoconf 2.61
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1644,7 +1644,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by yast2-sound $as_me 2.17.5, which was
+It was created by yast2-sound $as_me 2.17.6, which was
generated by GNU Autoconf 2.61. Invocation command line was
$ $0 $@
@@ -2465,7 +2465,7 @@
# Define the identity of the package.
PACKAGE='yast2-sound'
- VERSION='2.17.5'
+ VERSION='2.17.6'
cat >>confdefs.h <<_ACEOF
@@ -2693,7 +2693,7 @@
-VERSION="2.17.5"
+VERSION="2.17.6"
RPMNAME="yast2-sound"
MAINTAINER="Ladislav Slezak "
@@ -21901,7 +21901,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by yast2-sound $as_me 2.17.5, which was
+This file was extended by yast2-sound $as_me 2.17.6, which was
generated by GNU Autoconf 2.61. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -21954,7 +21954,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-yast2-sound config.status 2.17.5
+yast2-sound config.status 2.17.6
configured by $0, generated by GNU Autoconf 2.61,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/configure.in new/yast2-sound-2.17.6/configure.in
--- old/yast2-sound-2.17.5/configure.in 2008-10-06 17:22:42.000000000 +0200
+++ new/yast2-sound-2.17.6/configure.in 2008-10-07 18:22:30.000000000 +0200
@@ -3,7 +3,7 @@
dnl -- This file is generated by y2autoconf 2.17.3 - DO NOT EDIT! --
dnl (edit configure.in.in instead)
-AC_INIT(yast2-sound, 2.17.5, http://bugs.opensuse.org/, yast2-sound)
+AC_INIT(yast2-sound, 2.17.6, http://bugs.opensuse.org/, yast2-sound)
dnl Check for presence of file 'RPMNAME'
AC_CONFIG_SRCDIR([RPMNAME])
@@ -18,7 +18,7 @@
AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)
dnl Important YaST2 variables
-VERSION="2.17.5"
+VERSION="2.17.6"
RPMNAME="yast2-sound"
MAINTAINER="Ladislav Slezak "
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/sound/src/complex.ycp new/yast2-sound-2.17.6/sound/src/complex.ycp
--- old/yast2-sound-2.17.5/sound/src/complex.ycp 2008-09-11 10:43:07.000000000 +0200
+++ new/yast2-sound-2.17.6/sound/src/complex.ycp 2008-10-07 18:22:20.000000000 +0200
@@ -16,7 +16,7 @@
* String corrections by Christian Steinruecken , 2001/08/01
*
*
- * $Id: complex.ycp 51009 2008-09-11 08:43:06Z lslezak $
+ * $Id: complex.ycp 51938 2008-10-07 16:22:18Z lslezak $
*
*/
@@ -312,6 +312,14 @@
void PulseAudioPopup()
{
+ if (!Mode::config() && PulseAudio::Enabled() == nil)
+ {
+ y2error("PulseAudio status is nil - the setup script is missing?");
+ // error popup message
+ Popup::Error(_("PulseAudio is not installed or cannot be configured."));
+ return;
+ }
+
term dlg =
`HBox(
`HSpacing(1),
@@ -323,7 +331,7 @@
`VSpacing(0.5),
`Left(`CheckBox(`id(`pulseaudio),
// check box label
- _("&Enable PulseAudio Support"), PulseAudio::Enabled() != false)
+ _("&Enable PulseAudio Support"), PulseAudio::Enabled() == true)
),
`VSpacing(0.5)
)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/sound/src/PulseAudio.ycp new/yast2-sound-2.17.6/sound/src/PulseAudio.ycp
--- old/yast2-sound-2.17.5/sound/src/PulseAudio.ycp 2008-09-11 10:31:46.000000000 +0200
+++ new/yast2-sound-2.17.6/sound/src/PulseAudio.ycp 2008-10-07 17:02:49.000000000 +0200
@@ -32,19 +32,68 @@
module "PulseAudio";
textdomain "sound";
+import "FileUtils";
+import "Summary";
+
boolean pa_enabled = nil;
boolean modified = false;
+// path to the configuration script
+const string pa_setup_script = "/usr/bin/setup-pulseaudio";
+
global boolean Read()
{
+ // reset the modification flag
modified = false;
- y2warning("PulseAudio::Read() is not implemented!");
+
+ if (FileUtils::Exists(pa_setup_script))
+ {
+ map out = (map)SCR::Execute(.target.bash_output, pa_setup_script + " --status");
+ y2milestone("Read status: %1", out);
+
+ pa_enabled = regexpmatch(out["stdout"]:"", "^enabled");
+
+ y2milestone("PulseAudio is %1", pa_enabled ? "enabled" : "disabled");
+ }
+ else
+ {
+ y2warning("PulseAudio setup script %1 is not present!", pa_setup_script);
+ return false;
+ }
+
return true;
}
global boolean Write()
{
- y2warning("PulseAudio::Write() is not implemented!");
+ y2milestone("PulseAudio::Write(): pa_enabled: %1, modified: %2", pa_enabled, modified);
+
+ if (pa_enabled != nil && modified)
+ {
+ if (FileUtils::Exists(pa_setup_script))
+ {
+ y2milestone("%1 PulseAudio support", pa_enabled ? "Enabling" : "Disabling");
+
+ map out = (map)SCR::Execute(.target.bash_output, pa_setup_script +
+ (pa_enabled ? " --enable" : " --disable"));
+
+ y2milestone("Write status: %1", out);
+
+ // reset the modification flag
+ modified = false;
+ }
+ else
+ {
+ y2error("PulseAudio setup script %1 is not present, cannot activate the configuration!", pa_setup_script);
+ return false;
+ }
+ }
+ else
+ {
+ y2error("PulseAudio is not configured, cannot save activate configuration");
+ return false;
+ }
+
return true;
}
@@ -52,15 +101,16 @@
{
if (pa_enabled == nil)
{
- y2warning("PulseAudio is not configured");
- // summary string
- return _("PulseAudio is not configured");
+ return "";
}
- // summary string, %1 is "enabled" or "disabled"
- return sformat(_("PulseAudio is %1"),
- // part of a summary text (disabled/enabled status)
- pa_enabled ? _("enabled") : _("disabled"));
+ list<string> retlist = [
+ Summary::Device("PulseAudio",
+ // part of a summary text (PulseAudio is disabled/enabled)
+ (pa_enabled ? _("Enabled") : _("Disabled"))
+ )];
+
+ return Summary::DevicesList(retlist);
}
global void Reset()
@@ -70,6 +120,36 @@
modified = false;
}
+global map Export()
+{
+ if (pa_enabled == nil)
+ {
+ return $[];
+ }
+
+ return $[
+ "pulse_audio_status" : pa_enabled
+ ];
+}
+
+global boolean Import(map settings)
+{
+ if (haskey(settings, "pulse_audio_status"))
+ {
+ pa_enabled = settings["pulse_audio_status"]:false;
+ modified = true;
+
+ y2milestone("Imported PulseAudio configuration: pa_enabled: %1", pa_enabled);
+ }
+ else
+ {
+ y2milestone("The imported configuration doesn't contain PulseAudio configuration.");
+ pa_enabled = nil;
+ }
+
+ return true;
+}
+
global void Enable(boolean enable)
{
if (enable == nil)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/sound/src/sound_auto.ycp new/yast2-sound-2.17.6/sound/src/sound_auto.ycp
--- old/yast2-sound-2.17.5/sound/src/sound_auto.ycp 2008-09-11 10:43:07.000000000 +0200
+++ new/yast2-sound-2.17.6/sound/src/sound_auto.ycp 2008-10-07 18:22:20.000000000 +0200
@@ -11,7 +11,7 @@
* Authors:
* Dan Meszaros
*
- * $Id: sound_auto.ycp 51009 2008-09-11 08:43:06Z lslezak $
+ * $Id: sound_auto.ycp 51938 2008-10-07 16:22:18Z lslezak $
*
* This is a client for autoinstallation. It takes its arguments,
* goes through the configuration and return the setting.
@@ -109,11 +109,12 @@
/* Create a summary*/
if(func == "Import") {
- ret = Sound::Import(param);
+ ret = Sound::Import(param) && PulseAudio::Import(param);
}
/* Create a summary*/
else if(func == "Summary") {
- ret = Sound::Summary();
+ ret = Sound::Summary() + PulseAudio::Summary();
+ y2milestone("Sound card configuration summary: %1", ret);
}
else if (func == "GetModified") {
ret = Sound::GetModified();
@@ -125,6 +126,7 @@
/* Reset configuration */
else if (func == "Reset") {
Sound::Import($[]);
+ PulseAudio::Reset();
ret = $[];
}
/* Change configuration (run AutoSequence) TODO */
@@ -142,6 +144,11 @@
/* Return actual state */
else if (func == "Export") {
ret = Sound::Export();
+ // add PulseAudio config if it's defined
+ if (PulseAudio::Enabled() != nil)
+ {
+ ret = union((map)ret, PulseAudio::Export());
+ }
}
else if (func == "Read") {
PulseAudio::Read();
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/sound/src/sound.ycp new/yast2-sound-2.17.6/sound/src/sound.ycp
--- old/yast2-sound-2.17.5/sound/src/sound.ycp 2008-09-11 10:43:07.000000000 +0200
+++ new/yast2-sound-2.17.6/sound/src/sound.ycp 2008-10-07 18:22:20.000000000 +0200
@@ -12,7 +12,7 @@
* Dan Meszaros
* Jiri Suchomel
*
- * $Id: sound.ycp 51009 2008-09-11 08:43:06Z lslezak $
+ * $Id: sound.ycp 51938 2008-10-07 16:22:18Z lslezak $
*
* Installation of the sound card. If the sound card was not auto-detected ask user.
*
@@ -77,7 +77,9 @@
Sound::use_ui = false;
block<boolean> abort_block = ``{return false;};
- boolean ret = Sound::Read (false) && Joystick::Read(abort_block) && PulseAudio::Read();
+ boolean ret = Sound::Read (false) && Joystick::Read(abort_block);
+ // PulseAudio is optional, it may fail
+ PulseAudio::Read();
return ret;
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-sound-2.17.5/VERSION new/yast2-sound-2.17.6/VERSION
--- old/yast2-sound-2.17.5/VERSION 2008-10-06 17:20:37.000000000 +0200
+++ new/yast2-sound-2.17.6/VERSION 2008-10-07 17:09:49.000000000 +0200
@@ -1 +1 @@
-2.17.5
+2.17.6
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org