forked from pool/alsa-utils
This commit is contained in:
parent
548c5a376e
commit
9d11c63f53
86
alsa-utils-hg-fixes.diff
Normal file
86
alsa-utils-hg-fixes.diff
Normal file
@ -0,0 +1,86 @@
|
||||
diff -r dee0ae0aef39 alsactl/alsactl.c
|
||||
--- a/alsactl/alsactl.c Wed May 02 08:45:47 2007 +0200
|
||||
+++ b/alsactl/alsactl.c Thu May 24 12:49:32 2007 +0200
|
||||
@@ -41,16 +41,18 @@ static void help(void)
|
||||
{
|
||||
printf("Usage: alsactl <options> command\n");
|
||||
printf("\nAvailable options:\n");
|
||||
- printf(" -h,--help this help\n");
|
||||
- printf(" -f,--file # configuration file (default " SYS_ASOUNDRC " or " SYS_ASOUNDNAMES ")\n");
|
||||
- printf(" -F,--force try to restore the matching controls as much as possible\n");
|
||||
- printf(" -d,--debug debug mode\n");
|
||||
- printf(" -v,--version print version of this program\n");
|
||||
+ printf(" -h,--help this help\n");
|
||||
+ printf(" -f,--file # configuration file (default " SYS_ASOUNDRC " or " SYS_ASOUNDNAMES ")\n");
|
||||
+ printf(" -F,--force try to restore the matching controls as much as possible\n");
|
||||
+ printf(" -d,--debug debug mode\n");
|
||||
+ printf(" -v,--version print version of this program\n");
|
||||
printf("\nAvailable commands:\n");
|
||||
- printf(" store <card #> save current driver setup for one or each soundcards\n");
|
||||
- printf(" to configuration file\n");
|
||||
- printf(" restore<card #> load current driver setup for one or each soundcards\n");
|
||||
- printf(" from configuration file\n");
|
||||
+ printf(" store <card #> save current driver setup for one or each soundcards\n");
|
||||
+ printf(" to configuration file\n");
|
||||
+ printf(" restore <card #> load current driver setup for one or each soundcards\n");
|
||||
+ printf(" from configuration file\n");
|
||||
+ printf(" names <card #> dump information about all the known present (sub-)devices\n");
|
||||
+ printf(" into configuration file (DEPRECATED)\n");
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
diff -r dee0ae0aef39 alsactl/names.c
|
||||
--- a/alsactl/names.c Wed May 02 08:45:47 2007 +0200
|
||||
+++ b/alsactl/names.c Thu May 24 12:49:32 2007 +0200
|
||||
@@ -535,7 +535,7 @@ int generate_names(const char *cfgfile)
|
||||
err = snd_output_stdio_open(&out, cfgfile, "w+");
|
||||
}
|
||||
if (err < 0) {
|
||||
- error("Cannot open %s for writing", cfgfile);
|
||||
+ error("Cannot open %s for writing: %s", cfgfile, snd_strerror(err));
|
||||
return -errno;
|
||||
}
|
||||
err = snd_config_save(config, out);
|
||||
diff -r dee0ae0aef39 alsactl/state.c
|
||||
--- a/alsactl/state.c Wed May 02 08:45:47 2007 +0200
|
||||
+++ b/alsactl/state.c Thu May 24 12:49:32 2007 +0200
|
||||
@@ -1277,7 +1277,7 @@ int save_state(const char *file, const c
|
||||
else
|
||||
err = snd_output_stdio_open(&out, file, "w");
|
||||
if (err < 0) {
|
||||
- error("Cannot open %s for writing", file);
|
||||
+ error("Cannot open %s for writing: %s", file, snd_strerror(err));
|
||||
return -errno;
|
||||
}
|
||||
err = snd_config_save(config, out);
|
||||
@@ -1311,6 +1311,9 @@ int load_state(const char *file, const c
|
||||
error("snd_config_load error: %s", snd_strerror(err));
|
||||
return err;
|
||||
}
|
||||
+ } else {
|
||||
+ error("Cannot open %s for reading: %s", file, snd_strerror(err));
|
||||
+ return err;
|
||||
}
|
||||
|
||||
if (!cardname) {
|
||||
diff -r dee0ae0aef39 alsamixer/alsamixer.c
|
||||
--- a/alsamixer/alsamixer.c Wed May 02 08:45:47 2007 +0200
|
||||
+++ b/alsamixer/alsamixer.c Thu May 24 12:49:32 2007 +0200
|
||||
@@ -1787,8 +1787,15 @@ __again:
|
||||
}
|
||||
|
||||
if ( (mixer_view == VIEW_CAPTURE) || (mixer_view == VIEW_CHANNELS) ) {
|
||||
- if (snd_mixer_selem_has_capture_volume(elem) ||
|
||||
- (nelems_added == 0 && snd_mixer_selem_has_capture_switch(elem))) {
|
||||
+ int do_add = 0;
|
||||
+ if (snd_mixer_selem_has_capture_volume(elem) &&
|
||||
+ (mixer_view == VIEW_CAPTURE || !snd_mixer_selem_has_common_volume(elem)))
|
||||
+ do_add = 1;
|
||||
+ if (!do_add &&
|
||||
+ (nelems_added == 0 && snd_mixer_selem_has_capture_switch(elem)) &&
|
||||
+ (mixer_view == VIEW_CAPTURE || !snd_mixer_selem_has_common_switch(elem)))
|
||||
+ do_add = 1;
|
||||
+ if (do_add) {
|
||||
mixer_grpidx[elem_index] = idx;
|
||||
mixer_type[elem_index] = MIXER_ELEM_CAPTURE;
|
||||
if (nelems_added == 0 && snd_mixer_selem_has_capture_switch(elem))
|
@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu May 24 12:57:23 CEST 2007 - tiwai@suse.de
|
||||
|
||||
- HG patch as of 2007.05.24:
|
||||
* more error verbose messages in alsactl
|
||||
* fix duplicated mixer elements in alsamixer
|
||||
- Use find_lang
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 2 12:32:52 CEST 2007 - tiwai@suse.de
|
||||
|
||||
|
@ -20,9 +20,9 @@ Requires: dialog pciutils
|
||||
Autoreqprov: on
|
||||
Summary: Advanced Linux Sound Architecture Utilities
|
||||
Version: 1.0.13
|
||||
Release: 5
|
||||
Release: 10
|
||||
Source: ftp://ftp.alsa-project.org/pub/util/alsa-utils-%{package_version}.tar.bz2
|
||||
# Patch: alsa-utils-hg-fixes.diff
|
||||
Patch: alsa-utils-hg-fixes.diff
|
||||
URL: http://www.alsa-project.org/
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
|
||||
@ -39,7 +39,7 @@ Authors:
|
||||
|
||||
%prep
|
||||
%setup -n %{name}-%{package_version}
|
||||
# %patch -p1
|
||||
%patch -p1
|
||||
mv alsamixer/README alsamixer/README-alsamixer
|
||||
%{?suse_update_config:%{suse_update_config -f .}}
|
||||
|
||||
@ -50,11 +50,12 @@ make %{?jobs:-j %jobs}
|
||||
|
||||
%install
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
%find_lang %{name} --all-name
|
||||
|
||||
%clean
|
||||
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%files -f %{name}.lang
|
||||
%defattr(-, root, root)
|
||||
%doc COPYING ChangeLog INSTALL README TODO
|
||||
%doc alsamixer/README*
|
||||
@ -66,9 +67,13 @@ make DESTDIR=$RPM_BUILD_ROOT install
|
||||
%{_sbindir}/*
|
||||
%{_datadir}/sounds/alsa
|
||||
%{_datadir}/alsa
|
||||
%{_datadir}/locale/*/*/*
|
||||
|
||||
%changelog
|
||||
* Thu May 24 2007 - tiwai@suse.de
|
||||
- HG patch as of 2007.05.24:
|
||||
* more error verbose messages in alsactl
|
||||
* fix duplicated mixer elements in alsamixer
|
||||
- Use find_lang
|
||||
* Wed May 02 2007 - tiwai@suse.de
|
||||
- updated to version 1.0.14rc4
|
||||
including HG fixes
|
||||
|
Loading…
Reference in New Issue
Block a user