From 54c98f20200cf8b92bfcedaad1106a90f86b770b3c7f6cd4ab3016c0b5ceaba5 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Wed, 2 Sep 2009 05:51:18 +0000 Subject: [PATCH 1/5] fix build on old distros OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=8 --- alsa-utils.spec | 4 ---- 1 file changed, 4 deletions(-) diff --git a/alsa-utils.spec b/alsa-utils.spec index 9a0b3a2..048dd9a 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -33,7 +33,6 @@ Source: ftp://ftp.alsa-project.org/pub/util/alsa-utils-%{package_version # Patch: alsa-utils-git-fixes.diff Patch1: alsa-utils-gettext-version-removal.diff # Patch2: alsa-utils-po-pre-patch.diff -Patch3: alsa-utils-alsamixer-old-ncurses-fix.diff Url: http://www.alsa-project.org/ BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -59,9 +58,6 @@ sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am %if %suse_version < 1020 %patch1 -p1 %endif -%if %suse_version < 1110 -%patch3 -p1 -%endif %build %if %suse_version < 1020 From 0d6a85f33fcf6bb12c75991fe105c3cdbf2895010e674c3d525d42f3758e7321 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Wed, 2 Sep 2009 12:55:05 +0000 Subject: [PATCH 2/5] minor fixes OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=9 --- alsa-utils-git-fixes.diff | 74 +++++++++++++++++++++++++++++++++++++++ alsa-utils.changes | 6 ++++ alsa-utils.spec | 4 +-- 3 files changed, 82 insertions(+), 2 deletions(-) create mode 100644 alsa-utils-git-fixes.diff diff --git a/alsa-utils-git-fixes.diff b/alsa-utils-git-fixes.diff new file mode 100644 index 0000000..f4e7625 --- /dev/null +++ b/alsa-utils-git-fixes.diff @@ -0,0 +1,74 @@ +diff --git a/alsactl/init/default b/alsactl/init/default +index 8653ec6..a2069e3 100644 +--- a/alsactl/init/default ++++ b/alsactl/init/default +@@ -39,7 +39,7 @@ CTL{reset}="mixer" + CTL{name}="Front Playback Volume",PROGRAM!="__ctl_search",GOTO="front0_end" + # if master volume control is present, turn front volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="front0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="front0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="front0_end" + CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" + LABEL="front0_end" + CTL{name}="Front Playback Switch",PROGRAM=="__ctl_search", \ +@@ -49,15 +49,30 @@ CTL{reset}="mixer" + CTL{name}="Headphone Playback Volume",PROGRAM!="__ctl_search",GOTO="headphone0_end" + # if master volume control is present, turn headphone volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="headphone0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone0_end" + CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" + LABEL="headphone0_end" + CTL{name}="Headphone Playback Switch",PROGRAM=="__ctl_search", \ + CTL{values}="on" + + CTL{reset}="mixer" +-CTL{name}="Speaker Playback Volume",PROGRAM=="__ctl_search", \ +- CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++CTL{name}="Headphone Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search",\ ++ GOTO="headphone1_end" ++# if master volume control is present, turn headphone volume to max ++ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone1_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone1_end" ++CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++LABEL="headphone1_end" ++CTL{name}="Headphone Playback Switch",CTL{index}="1",PROGRAM=="__ctl_search", \ ++ CTL{values}="on" ++ ++CTL{reset}="mixer" ++CTL{name}="Sepaker Playback Volume",PROGRAM!="__ctl_search",GOTO="speaker0_end" ++# if master volume control is present, turn speaker volume to max ++ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="speaker0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="speaker0_end" ++CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++LABEL="speaker0_end" + CTL{name}="Speaker Playback Switch",PROGRAM=="__ctl_search", \ + CTL{values}="on" + +@@ -72,7 +87,7 @@ CTL{name}="PCM Playback Volume",PROGRAM!="__ctl_search", \ + CTL{name}="PCM Volume",PROGRAM!="__ctl_search", GOTO="pcm0_end" + # if master volume control is present, turn PCM volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm0_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm0_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm0_end" +@@ -86,7 +101,7 @@ CTL{name}="PCM Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search", \ + CTL{name}="PCM Volume",PROGRAM!="__ctl_search",GOTO="pcm1_end" + # if master volume control is present, turn PCM volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm1_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm1_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm1_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm1_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm1_end" +@@ -125,7 +140,7 @@ CTL{reset}="mixer" + CTL{name}="CD Playback Volume",PROGRAM!="__ctl_search", GOTO="cd0_end" + # if master volume control is present, turn CD volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="cd0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="cd0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="cd0_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="cd0_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="cd0_end" diff --git a/alsa-utils.changes b/alsa-utils.changes index 99c3940..dad3705 100644 --- a/alsa-utils.changes +++ b/alsa-utils.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Sep 2 14:52:56 CEST 2009 - tiwai@suse.de + +- fix build with older distros; removed an obsolete patch +- fix alsactl init syntax errors in the default config + ------------------------------------------------------------------- Mon Aug 31 17:27:36 CEST 2009 - tiwai@suse.de diff --git a/alsa-utils.spec b/alsa-utils.spec index 048dd9a..fd0214e 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -30,7 +30,7 @@ Summary: Advanced Linux Sound Architecture Utilities Version: 1.0.21 Release: 1 Source: ftp://ftp.alsa-project.org/pub/util/alsa-utils-%{package_version}.tar.bz2 -# Patch: alsa-utils-git-fixes.diff +Patch: alsa-utils-git-fixes.diff Patch1: alsa-utils-gettext-version-removal.diff # Patch2: alsa-utils-po-pre-patch.diff Url: http://www.alsa-project.org/ @@ -54,7 +54,7 @@ sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am # fix po changes in tarball first # %patch2 -p1 # rm -f po/Makefile* po/*.gmo po/*.pot po/*.header po/stamp-* -# %patch -p1 +%patch -p1 %if %suse_version < 1020 %patch1 -p1 %endif From 66f9102ae341e7adc973b46644cc913517ecc07be6c74ce6f9149bcc148bca29 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Thu, 3 Sep 2009 05:53:57 +0000 Subject: [PATCH 3/5] removed obsolete patch OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=10 --- alsa-utils-alsamixer-old-ncurses-fix.diff | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 alsa-utils-alsamixer-old-ncurses-fix.diff diff --git a/alsa-utils-alsamixer-old-ncurses-fix.diff b/alsa-utils-alsamixer-old-ncurses-fix.diff deleted file mode 100644 index dd41b24..0000000 --- a/alsa-utils-alsamixer-old-ncurses-fix.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/alsamixer/mainloop.c b/alsamixer/mainloop.c -index 7a5ffdc..388f962 100644 ---- a/alsamixer/mainloop.c -+++ b/alsamixer/mainloop.c -@@ -45,7 +45,7 @@ void initialize_curses(bool use_color) - cbreak(); - noecho(); - #ifdef NCURSES_VERSION -- set_escdelay(100); -+ // set_escdelay(100); - #endif - window_size_changed(); /* update screen_lines/cols */ - init_colors(use_color); From 084a40e97c9200a98b051925f8c10949fe511907c96566c40967713a23863b1d Mon Sep 17 00:00:00 2001 From: OBS User autobuild Date: Thu, 3 Sep 2009 16:05:32 +0000 Subject: [PATCH 4/5] checked in OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=11 --- alsa-utils-alsamixer-old-ncurses-fix.diff | 13 ++++ alsa-utils-git-fixes.diff | 74 ----------------------- alsa-utils.changes | 6 -- alsa-utils.spec | 8 ++- 4 files changed, 19 insertions(+), 82 deletions(-) create mode 100644 alsa-utils-alsamixer-old-ncurses-fix.diff delete mode 100644 alsa-utils-git-fixes.diff diff --git a/alsa-utils-alsamixer-old-ncurses-fix.diff b/alsa-utils-alsamixer-old-ncurses-fix.diff new file mode 100644 index 0000000..dd41b24 --- /dev/null +++ b/alsa-utils-alsamixer-old-ncurses-fix.diff @@ -0,0 +1,13 @@ +diff --git a/alsamixer/mainloop.c b/alsamixer/mainloop.c +index 7a5ffdc..388f962 100644 +--- a/alsamixer/mainloop.c ++++ b/alsamixer/mainloop.c +@@ -45,7 +45,7 @@ void initialize_curses(bool use_color) + cbreak(); + noecho(); + #ifdef NCURSES_VERSION +- set_escdelay(100); ++ // set_escdelay(100); + #endif + window_size_changed(); /* update screen_lines/cols */ + init_colors(use_color); diff --git a/alsa-utils-git-fixes.diff b/alsa-utils-git-fixes.diff deleted file mode 100644 index f4e7625..0000000 --- a/alsa-utils-git-fixes.diff +++ /dev/null @@ -1,74 +0,0 @@ -diff --git a/alsactl/init/default b/alsactl/init/default -index 8653ec6..a2069e3 100644 ---- a/alsactl/init/default -+++ b/alsactl/init/default -@@ -39,7 +39,7 @@ CTL{reset}="mixer" - CTL{name}="Front Playback Volume",PROGRAM!="__ctl_search",GOTO="front0_end" - # if master volume control is present, turn front volume to max - ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="front0_end" --ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="front0_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="front0_end" - CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" - LABEL="front0_end" - CTL{name}="Front Playback Switch",PROGRAM=="__ctl_search", \ -@@ -49,15 +49,30 @@ CTL{reset}="mixer" - CTL{name}="Headphone Playback Volume",PROGRAM!="__ctl_search",GOTO="headphone0_end" - # if master volume control is present, turn headphone volume to max - ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone0_end" --ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="headphone0_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone0_end" - CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" - LABEL="headphone0_end" - CTL{name}="Headphone Playback Switch",PROGRAM=="__ctl_search", \ - CTL{values}="on" - - CTL{reset}="mixer" --CTL{name}="Speaker Playback Volume",PROGRAM=="__ctl_search", \ -- CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" -+CTL{name}="Headphone Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search",\ -+ GOTO="headphone1_end" -+# if master volume control is present, turn headphone volume to max -+ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone1_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone1_end" -+CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" -+LABEL="headphone1_end" -+CTL{name}="Headphone Playback Switch",CTL{index}="1",PROGRAM=="__ctl_search", \ -+ CTL{values}="on" -+ -+CTL{reset}="mixer" -+CTL{name}="Sepaker Playback Volume",PROGRAM!="__ctl_search",GOTO="speaker0_end" -+# if master volume control is present, turn speaker volume to max -+ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="speaker0_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="speaker0_end" -+CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" -+LABEL="speaker0_end" - CTL{name}="Speaker Playback Switch",PROGRAM=="__ctl_search", \ - CTL{values}="on" - -@@ -72,7 +87,7 @@ CTL{name}="PCM Playback Volume",PROGRAM!="__ctl_search", \ - CTL{name}="PCM Volume",PROGRAM!="__ctl_search", GOTO="pcm0_end" - # if master volume control is present, turn PCM volume to max - ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm0_end" --ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm0_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm0_end" - # exception - some HDA codecs have shifted dB range - CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm0_end" - CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm0_end" -@@ -86,7 +101,7 @@ CTL{name}="PCM Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search", \ - CTL{name}="PCM Volume",PROGRAM!="__ctl_search",GOTO="pcm1_end" - # if master volume control is present, turn PCM volume to max - ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm1_end" --ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm1_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm1_end" - # exception - some HDA codecs have shifted dB range - CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm1_end" - CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm1_end" -@@ -125,7 +140,7 @@ CTL{reset}="mixer" - CTL{name}="CD Playback Volume",PROGRAM!="__ctl_search", GOTO="cd0_end" - # if master volume control is present, turn CD volume to max - ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="cd0_end" --ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="cd0_end" -+ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="cd0_end" - # exception - some HDA codecs have shifted dB range - CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="cd0_end" - CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="cd0_end" diff --git a/alsa-utils.changes b/alsa-utils.changes index dad3705..99c3940 100644 --- a/alsa-utils.changes +++ b/alsa-utils.changes @@ -1,9 +1,3 @@ -------------------------------------------------------------------- -Wed Sep 2 14:52:56 CEST 2009 - tiwai@suse.de - -- fix build with older distros; removed an obsolete patch -- fix alsactl init syntax errors in the default config - ------------------------------------------------------------------- Mon Aug 31 17:27:36 CEST 2009 - tiwai@suse.de diff --git a/alsa-utils.spec b/alsa-utils.spec index fd0214e..9a0b3a2 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -30,9 +30,10 @@ Summary: Advanced Linux Sound Architecture Utilities Version: 1.0.21 Release: 1 Source: ftp://ftp.alsa-project.org/pub/util/alsa-utils-%{package_version}.tar.bz2 -Patch: alsa-utils-git-fixes.diff +# Patch: alsa-utils-git-fixes.diff Patch1: alsa-utils-gettext-version-removal.diff # Patch2: alsa-utils-po-pre-patch.diff +Patch3: alsa-utils-alsamixer-old-ncurses-fix.diff Url: http://www.alsa-project.org/ BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -54,10 +55,13 @@ sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am # fix po changes in tarball first # %patch2 -p1 # rm -f po/Makefile* po/*.gmo po/*.pot po/*.header po/stamp-* -%patch -p1 +# %patch -p1 %if %suse_version < 1020 %patch1 -p1 %endif +%if %suse_version < 1110 +%patch3 -p1 +%endif %build %if %suse_version < 1020 From c01751940ed7e54cac8cfef855eae1945f31602bf2c3acd43a0aaf8797101ce1 Mon Sep 17 00:00:00 2001 From: OBS User buildservice-autocommit Date: Thu, 3 Sep 2009 16:05:33 +0000 Subject: [PATCH 5/5] Updating link to change in openSUSE:Factory/alsa-utils revision 36.0 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=39f2b2ea822afd0daea432e8d2c0a93b --- alsa-utils-alsamixer-old-ncurses-fix.diff | 13 ---- alsa-utils-git-fixes.diff | 74 +++++++++++++++++++++++ alsa-utils.changes | 6 ++ alsa-utils.spec | 10 +-- 4 files changed, 83 insertions(+), 20 deletions(-) delete mode 100644 alsa-utils-alsamixer-old-ncurses-fix.diff create mode 100644 alsa-utils-git-fixes.diff diff --git a/alsa-utils-alsamixer-old-ncurses-fix.diff b/alsa-utils-alsamixer-old-ncurses-fix.diff deleted file mode 100644 index dd41b24..0000000 --- a/alsa-utils-alsamixer-old-ncurses-fix.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/alsamixer/mainloop.c b/alsamixer/mainloop.c -index 7a5ffdc..388f962 100644 ---- a/alsamixer/mainloop.c -+++ b/alsamixer/mainloop.c -@@ -45,7 +45,7 @@ void initialize_curses(bool use_color) - cbreak(); - noecho(); - #ifdef NCURSES_VERSION -- set_escdelay(100); -+ // set_escdelay(100); - #endif - window_size_changed(); /* update screen_lines/cols */ - init_colors(use_color); diff --git a/alsa-utils-git-fixes.diff b/alsa-utils-git-fixes.diff new file mode 100644 index 0000000..f4e7625 --- /dev/null +++ b/alsa-utils-git-fixes.diff @@ -0,0 +1,74 @@ +diff --git a/alsactl/init/default b/alsactl/init/default +index 8653ec6..a2069e3 100644 +--- a/alsactl/init/default ++++ b/alsactl/init/default +@@ -39,7 +39,7 @@ CTL{reset}="mixer" + CTL{name}="Front Playback Volume",PROGRAM!="__ctl_search",GOTO="front0_end" + # if master volume control is present, turn front volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="front0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="front0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="front0_end" + CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" + LABEL="front0_end" + CTL{name}="Front Playback Switch",PROGRAM=="__ctl_search", \ +@@ -49,15 +49,30 @@ CTL{reset}="mixer" + CTL{name}="Headphone Playback Volume",PROGRAM!="__ctl_search",GOTO="headphone0_end" + # if master volume control is present, turn headphone volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="headphone0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone0_end" + CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" + LABEL="headphone0_end" + CTL{name}="Headphone Playback Switch",PROGRAM=="__ctl_search", \ + CTL{values}="on" + + CTL{reset}="mixer" +-CTL{name}="Speaker Playback Volume",PROGRAM=="__ctl_search", \ +- CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++CTL{name}="Headphone Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search",\ ++ GOTO="headphone1_end" ++# if master volume control is present, turn headphone volume to max ++ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="headphone1_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="headphone1_end" ++CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++LABEL="headphone1_end" ++CTL{name}="Headphone Playback Switch",CTL{index}="1",PROGRAM=="__ctl_search", \ ++ CTL{values}="on" ++ ++CTL{reset}="mixer" ++CTL{name}="Sepaker Playback Volume",PROGRAM!="__ctl_search",GOTO="speaker0_end" ++# if master volume control is present, turn speaker volume to max ++ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="speaker0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="speaker0_end" ++CTL{values}="$env{pvolume}",RESULT!="0",CTL{values}="$env{ppercent}" ++LABEL="speaker0_end" + CTL{name}="Speaker Playback Switch",PROGRAM=="__ctl_search", \ + CTL{values}="on" + +@@ -72,7 +87,7 @@ CTL{name}="PCM Playback Volume",PROGRAM!="__ctl_search", \ + CTL{name}="PCM Volume",PROGRAM!="__ctl_search", GOTO="pcm0_end" + # if master volume control is present, turn PCM volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm0_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm0_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm0_end" +@@ -86,7 +101,7 @@ CTL{name}="PCM Playback Volume",CTL{index}="1",PROGRAM!="__ctl_search", \ + CTL{name}="PCM Volume",PROGRAM!="__ctl_search",GOTO="pcm1_end" + # if master volume control is present, turn PCM volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="pcm1_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="pcm1_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="pcm1_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="pcm1_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="pcm1_end" +@@ -125,7 +140,7 @@ CTL{reset}="mixer" + CTL{name}="CD Playback Volume",PROGRAM!="__ctl_search", GOTO="cd0_end" + # if master volume control is present, turn CD volume to max + ENV{has_pmaster_vol}=="true",CTL{values}="0dB",RESULT=="0",GOTO="cd0_end" +-ENV{has_pmaster_vol}=="true",CTL{values)="100%",GOTO="cd0_end" ++ENV{has_pmaster_vol}=="true",CTL{values}="100%",GOTO="cd0_end" + # exception - some HDA codecs have shifted dB range + CTL{dBmin}=="-34.50dB",CTL{dBmax}=="12.00dB",CTL{values}="0dB",GOTO="cd0_end" + CTL{dBmin}=="-30.00dB",CTL{dBmax}=="0dB",CTL{values}="0dB",GOTO="cd0_end" diff --git a/alsa-utils.changes b/alsa-utils.changes index 99c3940..dad3705 100644 --- a/alsa-utils.changes +++ b/alsa-utils.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Sep 2 14:52:56 CEST 2009 - tiwai@suse.de + +- fix build with older distros; removed an obsolete patch +- fix alsactl init syntax errors in the default config + ------------------------------------------------------------------- Mon Aug 31 17:27:36 CEST 2009 - tiwai@suse.de diff --git a/alsa-utils.spec b/alsa-utils.spec index 9a0b3a2..07fc64b 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -28,12 +28,11 @@ Requires: dialog pciutils AutoReqProv: on Summary: Advanced Linux Sound Architecture Utilities Version: 1.0.21 -Release: 1 +Release: 2 Source: ftp://ftp.alsa-project.org/pub/util/alsa-utils-%{package_version}.tar.bz2 -# Patch: alsa-utils-git-fixes.diff +Patch: alsa-utils-git-fixes.diff Patch1: alsa-utils-gettext-version-removal.diff # Patch2: alsa-utils-po-pre-patch.diff -Patch3: alsa-utils-alsamixer-old-ncurses-fix.diff Url: http://www.alsa-project.org/ BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -55,13 +54,10 @@ sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am # fix po changes in tarball first # %patch2 -p1 # rm -f po/Makefile* po/*.gmo po/*.pot po/*.header po/stamp-* -# %patch -p1 +%patch -p1 %if %suse_version < 1020 %patch1 -p1 %endif -%if %suse_version < 1110 -%patch3 -p1 -%endif %build %if %suse_version < 1020